-
Notifications
You must be signed in to change notification settings - Fork 474
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docs: added pomerium as a reverse proxy option #10453
base: master
Are you sure you want to change the base?
Conversation
@nickytonline is attempting to deploy a commit to the PostHog Team on Vercel. A member of the Team first needs to authorize it. |
|
||
#### Create an Optional Allow All Policy | ||
|
||
1. [Log in to Pomerium Zero](https://console.pomerium.app/). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have screenshots I can add here @ivanagas, but I noticed the others had none, so omitted them for the time being. Also, for images from non-PostHog ones, where would you want them? e.g. /contents/docs/_media/pomerium
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feel free to add them here and I'll upload them to our CDN and send them back to you
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Don't know if others run into this issue, but I had to up the default max listeners to 15 in gatsby-node.ts, otherwise the dev build errors out. + const events = require('events');
+ events.EventEmitter.defaultMaxListeners = 15;
import path from 'path'
import { GatsbyNode } from 'gatsby'
const axios = require('axios')
export { createPages } from './gatsby/createPages'
export { onCreateNode, onPreInit } from './gatsby/onCreateNode'
export { createSchemaCustomization } from './gatsby/createSchemaCustomization'
export { sourceNodes } from './gatsby/sourceNodes'
export { onPostBuild } from './gatsby/onPostBuild'
export { createResolvers } from './gatsby/createResolvers'
export { onPreBootstrap } from './gatsby/onPreBootstrap'
// Implement the Gatsby API “onCreatePage”. This is
// called after every page is created.
export const onCreatePage: GatsbyNode['onCreatePage'] = async ({ page, actions }) => {
const { createPage } = actions
if (page.path.match(/^\/community\/profiles/)) {
page.matchPath = '/community/profiles/*'
createPage(page)
}
if (page.path.match(/^\/next\-steps/)) {
page.matchPath = '/next-steps/*'
createPage(page)
}
}
export const onCreateWebpackConfig: GatsbyNode['onCreateWebpackConfig'] = ({ stage, actions }) => {
actions.setWebpackConfig({
cache: process.env.NODE_ENV === 'development' || {
compression: 'gzip',
},
resolve: {
extensions: ['.js', '.ts', '.tsx'],
alias: {
'~': path.resolve(__dirname, 'src'),
lib: path.resolve(__dirname, 'src', 'lib'),
types: path.resolve(__dirname, 'src', 'types'),
images: path.resolve(__dirname, 'src', 'images'),
components: path.resolve(__dirname, 'src', 'components'),
logic: path.resolve(__dirname, 'src', 'logic'),
hooks: path.resolve(__dirname, 'src', 'hooks'),
},
},
})
}
exports.createPages = async ({ actions }) => {
const { createPage } = actions
try {
const response = await axios.get('https://jobs.ashbyhq.com/supabase')
const jobData = JSON.parse(response.data)
const jobs = jobData?.jobBoard?.jobPostings || []
// Create the jobs page with the data
createPage({
path: '/jobs',
component: require.resolve('./src/templates/jobs.tsx'),
context: {
jobs: jobs,
},
})
} catch (error) {
console.error('Error fetching jobs:', error)
}
} |
You want to change this from a draft PR? I'll review it once your ready and deal with any of the build issues :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, but just making sure the headers are good.
I'll also add it to the nav properly
|
||
#### Create an Optional Allow All Policy | ||
|
||
1. [Log in to Pomerium Zero](https://console.pomerium.app/). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feel free to add them here and I'll upload them to our CDN and send them back to you
Ahh missed that. 😅 |
Co-authored-by: Ian Vanagas <[email protected]>
Co-authored-by: Ian Vanagas <[email protected]>
Co-authored-by: Ian Vanagas <[email protected]>
Co-authored-by: Ian Vanagas <[email protected]>
Co-authored-by: Ian Vanagas <[email protected]>
Co-authored-by: Ian Vanagas <[email protected]>
Changes
This PR adds documentation for configuring Pomerium as a reverse proxy for PostHog.
Closes #10360
Checklist
vercel.json