-
Notifications
You must be signed in to change notification settings - Fork 87
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
NODE_ENV for development and production #161
Comments
For sure. Will just add some BASH here that will change the command based on the branch. |
Ultimately, will the main/master branch be what you want displayed at https://ceph.io? |
Yep, that was my understanding.
Though it might be worth raising with the group? Once we move beyond launch, will the team want to maintain a development environment to collect updates in (and ultimately push up to master/prod to publish), or will the expectation be that users feature-branch from master and cut-out the middleman? |
Please do raise with the group. For me, personally, I think it makes more sense to push |
Yep, perfect. So each branch deploy is accessible from its branch-name subdomain (as it is currently). All branch deploys will run @Thingee — is that how you envisage we'll be managing content updates/branch previews? |
@adamduncan I've completed these tasks and they're working fine; however, I've noticed a warning in the browser console I haven't spotted anything else obvious that we can use the |
@Pete-Robelou Do you have a PR you can publish exhibiting this error? I can take a look to see if anything jumps out. |
PR is here #170. |
Thanks @Pete-Robelou. Commented over there. |
All resolved on the PR. |
Let me know when I should do this |
Let's just use the branch previews. |
With |
Fixes: ceph/ceph.io#161 Signed-off-by: David Galloway <[email protected]>
With it decided that we'll just be working from a The website changes required for this ticket have been completed and merged (#170) |
In order to leverage environment-specific control over certain site features, we should differentiate between builds for
production
anddevelopment
.We currently just
build
withNODE_ENV=production
assumed. Let's rework these scripts to support both, by setting theNODE_ENV
appropriately, e.g. something like...?This way we'll be able to reference
process.env.NODE_ENV
available at build-time.isProduction
variable in our_data/site.json
as a Boolean (e.g.isProduction: process.env.NODE_ENV === 'production'
)site.isProduction
in scenarios where we need environment-specific control, e.g.<meta name="robots" content="noindex, nofollow">
if not productionGoogle Analytics snippet(Set up and implement analytics #191)@djgalloway — Will need support on how we might differentiate the two environments in our build config. Will it be possible to trigger
npm run build:development
andnpm run build:production
for https://develop.ceph.io and https://ceph.io, respectively (in place of the genericnpm run build
we use for both envs currently)?The text was updated successfully, but these errors were encountered: