You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This was initially opened under a feature request #38529. The idea is to add https support to the gatsby serve command that exists in the gatsby develop command
Try it out
I would like to add the following parameters to the gatsby serve command, these are copied exactly from the gatsby develop command.
-S, --https Use HTTPS. See https://www.gatsbyjs.com/docs/local-https/ as a guide [boolean]
-c, --cert-file Custom HTTPS cert file (also required: --https, --key-file). See https://www.gatsbyjs.com/docs/local-https/ [string] [default: ""]
-k, --key-file Custom HTTPS key file (also required: --https, --cert-file). See https://www.gatsbyjs.com/docs/local-https/ [string] [default: ""]
--ca-file Custom HTTPS CA certificate file (also required: --https, --cert-file, --key-file). See https://www.gatsbyjs.com/docs/local-https/ [string] [default: ""]
CodeSandbox
TBD, waiting on approval of this before submitting a branch that does this.
Basic example
N/A
Motivation
Cloud and Kubernetes. Running Gatsby through the netlify cloud and a couple other provides is pretty well integrated, actually seamless. The problem is when you stray outside of that it's pretty hard to get the full functionality of SSR/DSG with Gatsby in the Kubernetes/Docker environment. There has been a couple attempts of writing plugins for this however they are outdated and are not maintained. The [Gatsby docs themselves] (https://www.gatsbyjs.com/docs/reference/rendering-options/deferred-static-generation/)
Note: This feature requires running NodeJS server. It is currently fully supported with [gatsby serve](https://www.gatsbyjs.com/docs/reference/gatsby-cli/#serve) and in [Gatsby Cloud](https://www.gatsbyjs.com/products/cloud/).
mention that DSG is fully supported in the gatsby serve command and in the Gatsby cloud. That isn't quite the case as industry compliances require running ssl from the edge to the application. There are two plugins that expose Gatsby through express but they are way outdated and not maintained.
Copying the implementation from gatsby serve to gatsby develop for taking in https certificate info.
Drawbacks
The only thing that I can think of is I remember seeing in the docs somewhere it said not to use gatsby serve in production but there is an occurrence under the DSG docs that mentions to use gatsby serve to get DSG.
Alternatives
The plugins are way out of the date and mostly need to be rewritten top to bottom to update to the latest version of Gatsby.
Adoption strategy
No code mods are needed, this is just a documentation update.
How we teach this
This is pretty easy as well as just updating documentation.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Summary
This was initially opened under a feature request #38529. The idea is to add https support to the
gatsby serve
command that exists in thegatsby develop
commandTry it out
I would like to add the following parameters to the
gatsby serve
command, these are copied exactly from thegatsby develop
command.CodeSandbox
TBD, waiting on approval of this before submitting a branch that does this.
Basic example
N/A
Motivation
Cloud and Kubernetes. Running Gatsby through the netlify cloud and a couple other provides is pretty well integrated, actually seamless. The problem is when you stray outside of that it's pretty hard to get the full functionality of SSR/DSG with Gatsby in the Kubernetes/Docker environment. There has been a couple attempts of writing plugins for this however they are outdated and are not maintained. The [Gatsby docs themselves] (https://www.gatsbyjs.com/docs/reference/rendering-options/deferred-static-generation/)
Note: This feature requires running NodeJS server. It is currently fully supported with [gatsby serve](https://www.gatsbyjs.com/docs/reference/gatsby-cli/#serve) and in [Gatsby Cloud](https://www.gatsbyjs.com/products/cloud/).
mention that DSG is fully supported in the
gatsby serve
command and in the Gatsby cloud. That isn't quite the case as industry compliances require running ssl from the edge to the application. There are two plugins that expose Gatsby through express but they are way outdated and not maintained.Detailed design
Copying the implementation from
gatsby serve
togatsby develop
for taking in https certificate info.Drawbacks
The only thing that I can think of is I remember seeing in the docs somewhere it said not to use
gatsby serve
in production but there is an occurrence under the DSG docs that mentions to usegatsby serve
to get DSG.Alternatives
The plugins are way out of the date and mostly need to be rewritten top to bottom to update to the latest version of Gatsby.
Adoption strategy
No code mods are needed, this is just a documentation update.
How we teach this
This is pretty easy as well as just updating documentation.
Unresolved questions
N/A
Beta Was this translation helpful? Give feedback.
All reactions