shift-org / shift-docs

Shift2Bikes: website and calendar for shift and pedalpalooza
https://shift2bikes.org
Other
22 stars 17 forks source link

duality test #665

Closed ionous closed 8 months ago

ionous commented 8 months ago

this pr does two things:

  1. on the backend, adds the node server as a sibling container to the php container; listening for incoming requests on /api2/ endpoints
  2. on the frontend ( https://deploy-preview-665--shift-docs.netlify.app/ ) changes the netlify.toml to redirect api calls to https://api.shift2bikes.org/api2/ -- EDIT: see comment below, i updated the PR to keep the toml pointing to "api" ( php ); the necessary comments are in there so we can easily create a second PR to swap to "api2" ( node ) if we decide to apply this PR to the backend.

the rest of the frontend and backend are the same as they always have been. so, if we deployed the backend code to the production server, we could switch freely between php and node just by switching the toml.

ionous commented 8 months ago

i've switched the toml back to the normal php endpoint; so that this could ( in theory ) be deployed without mucking up the site. and then a new pr could be created for seeing api2