From c7684185971f4ddde81706de3167bb7ec4f876c4 Mon Sep 17 00:00:00 2001 From: Cole Crawford Date: Tue, 6 Sep 2022 00:54:40 -0400 Subject: [PATCH] Add docker compose for frontend --- .gitignore | 1 + Dockerfile | 10 +--------- docker-compose.yml | 48 ++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 50 insertions(+), 9 deletions(-) create mode 100644 docker-compose.yml diff --git a/.gitignore b/.gitignore index 5d313f39..9546e99d 100644 --- a/.gitignore +++ b/.gitignore @@ -39,3 +39,4 @@ Thumbs.db .env*.local doc/ +.env diff --git a/Dockerfile b/Dockerfile index 1e36d0e3..3fa45d26 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,12 +14,4 @@ RUN yarn build FROM nginx:1.13.9-alpine COPY --from=builder /app/build /usr/share/nginx/html EXPOSE 80 -CMD ["nginx", "-g", "daemon off;"] - - - - - - - - +CMD ["nginx", "-g", "daemon off;"] \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 00000000..7d578eb7 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,48 @@ +services: + static: + image: node:9.6.1 + volumes: + - .:/app + working_dir: /app + command: /bin/sh -c 'yarn && yarn start' + ports: + - 3000:3000 + environment: + REACT_APP_GRAPHQL_SERVER: http://localhost:3001 # http://api.orpheus.local:3001 + REACT_APP_GRAPHQL_URI: graphql + REACT_APP_SERVER: http://localhost:3001 # http://api.orpheus.local:3001 + REACT_APP_LOGIN_URI: auth/login + REACT_APP_LOGOUT_URI: auth/logout + REACT_APP_REGISTER_URI: auth/register + REACT_APP_VERIFY_TOKEN_URI: auth/verify-token + REACT_APP_WORDPRESS_UPLOADS_URL: http://slab.loc/app/uploads/ + # REACT_APP_COOKIE_DOMAIN: mindthegap.orpheus.local + # REACT_APP_BUCKET_URL: https://s3.amazonaws.com/iiif-orpheus + # REACT_APP_FACEBOOK_CLIENT_ID: client_id + # REACT_APP_GOOGLE_CLIENT_ID: client_id + # REACT_APP_TWITTER_CLIENT_ID: client_id + # REACT_APP_GOOGLE_MAPS_API_KEY: mapkey + + + # client: + # build: + # context: . + # dockerfile: ./Dockerfile + # image: soundlab-client + # ports: + # - 3000:80 + # environment: + # REACT_APP_GRAPHQL_SERVER: http://localhost:3001 # http://api.orpheus.local:3001 + # REACT_APP_GRAPHQL_URI: graphql + # REACT_APP_SERVER: http://localhost:3001 # http://api.orpheus.local:3001 + # REACT_APP_LOGIN_URI: auth/login + # REACT_APP_LOGOUT_URI: auth/logout + # REACT_APP_REGISTER_URI: auth/register + # REACT_APP_VERIFY_TOKEN_URI: auth/verify-token + # # REACT_APP_COOKIE_DOMAIN: mindthegap.orpheus.local + # # REACT_APP_BUCKET_URL: https://s3.amazonaws.com/iiif-orpheus + # # REACT_APP_FACEBOOK_CLIENT_ID: client_id + # # REACT_APP_GOOGLE_CLIENT_ID: client_id + # # REACT_APP_TWITTER_CLIENT_ID: client_id + # # REACT_APP_GOOGLE_MAPS_API_KEY: mapkey + \ No newline at end of file