docs: Clarify how to setup Docker with custom Server File #10702
+64
−8
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Clarify how to setup Docker with custom Server File.
While the Docker documentation does instruct how to user Docker with the custom server file, the instructions could be easily missed.
In the follow support issue https://community.redwoodjs.com/t/unknown-directive-live-in-docker/7150/7 redwoodJS was setup to use Docker and also GraphQL with Realtime.
Realtime (and live queries) worked with rw dev, api set and also Docker dev -- but not production Docker.
In production Docker, the server file was never run and therefore the plugin to setup GraphQL with the useRedwoodRealtime plugin never happened ... and thus the live directive wasn't understood nor were GraphQL subscripts added to the schema.
Here api server, simply ran the GraphQL function as expected, but the plugin was never invoked so Realtime was never configured or added to the schema.
This happened because by default, production Docker launch the plain vanilla api server -- it didn't launch server file that uses
createServer
to setup a separate GraphQL server and also add in the realtime plugin.This PR: