From 692a362b9037b6425c8f9caa26e4ebfa45c16a83 Mon Sep 17 00:00:00 2001 From: Frederic Maury Date: Fri, 30 Aug 2024 10:48:55 +0200 Subject: [PATCH] feat: update build files --- .dockerignore | 13 +++++++++++++ backend/.dockerignore | 3 ++- docker-compose.yml | 8 +++++--- frontend/Dockerfile | 10 +++++++--- frontend/example.env | 8 +++++--- 5 files changed, 32 insertions(+), 10 deletions(-) create mode 100644 .dockerignore diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..81e9919 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,13 @@ +.vscode +.DS_STORE +.env +tmp +Dockerfile* +docker-compose* +.dockerignore +*.md +.git +.gitignore +node_modules +npm-debug.log +tests/ \ No newline at end of file diff --git a/backend/.dockerignore b/backend/.dockerignore index 3bb6390..fd95e7f 100644 --- a/backend/.dockerignore +++ b/backend/.dockerignore @@ -7,4 +7,5 @@ docker-compose* .dockerignore *.md .git -.gitignore \ No newline at end of file +.gitignore +node_modules \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index beb7492..3b5a1b1 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -8,9 +8,11 @@ services: - 80:3010 environment: - REACT_APP_REALT_PROPERTIES_BACKEND_URL=http://localhost:3000/ - - REACT_APP_REALT_THEGRAPH_URL=https://api.thegraph.com/subgraphs/name/realtoken-thegraph/ - - REACT_APP_REALT_THEGRAPH_GNOSIS=realtoken-xdai - - REACT_APP_REALT_THEGRAPH_RMM=rmm-v3-wrapper-gnosis + - REACT_APP_REALT_THEGRAPH_URL=https://gateway-arbitrum.network.thegraph.com/api/ + - REACT_APP_REALT_THEGRAPH_API_KEY= + - REACT_APP_REALT_THEGRAPH_RMM=subgraphs/id/9Ut97U2oMKwRucppj7fdMeZ8oFCJrUYyr8wu4hFXBn7Y + - REACT_APP_REALT_THEGRAPH_GNOSIS=subgraphs/id/FPPoFB7S2dcCNrRyjM5QbaMwKqRZPdbTg8ysBrwXd4SP + - REACT_APP_REALT_THEGRAPH_ETH=subgraphs/id/EVjGN4mMd9h9JfGR7yLC6T2xrJf9syhjQNboFb7GzxVW volumes: - ./frontend:/app command: [sh, -c, 'cd /app && npm start'] diff --git a/frontend/Dockerfile b/frontend/Dockerfile index ea1e5d2..ebed3e1 100644 --- a/frontend/Dockerfile +++ b/frontend/Dockerfile @@ -1,8 +1,10 @@ ARG NODE_IMAGE=node:21-alpine ARG REACT_APP_REALT_PROPERTIES_BACKEND_URL -ARG REACT_APP_REALT_THEGRAPH_URL=https://api.thegraph.com/subgraphs/name/realtoken-thegraph/ -ARG REACT_APP_REALT_THEGRAPH_GNOSIS=realtoken-xdai -ARG REACT_APP_REALT_THEGRAPH_RMM=rmm-v3-wrapper-gnosis +ARG REACT_APP_REALT_THEGRAPH_URL=https://gateway-arbitrum.network.thegraph.com/api/ +ARG REACT_APP_REALT_THEGRAPH_API_KEY +ARG REACT_APP_REALT_THEGRAPH_GNOSIS=subgraphs/id/FPPoFB7S2dcCNrRyjM5QbaMwKqRZPdbTg8ysBrwXd4SP +ARG REACT_APP_REALT_THEGRAPH_RMM=rsubgraphs/id/9Ut97U2oMKwRucppj7fdMeZ8oFCJrUYyr8wu4hFXBn7Y +ARG REACT_APP_REALT_THEGRAPH_ETH=subgraphs/id/EVjGN4mMd9h9JfGR7yLC6T2xrJf9syhjQNboFb7GzxVW FROM $NODE_IMAGE AS dependencies WORKDIR /app @@ -14,8 +16,10 @@ FROM dependencies as build ENV NODE_ENV=production ENV REACT_APP_REALT_PROPERTIES_BACKEND_URL=$REACT_APP_REALT_PROPERTIES_BACKEND_URL ENV REACT_APP_REALT_THEGRAPH_URL=$REACT_APP_REALT_THEGRAPH_URL +ENV REACT_APP_REALT_THEGRAPH_API_KEY=$REACT_APP_REALT_THEGRAPH_API_KEY ENV REACT_APP_REALT_THEGRAPH_GNOSIS=$REACT_APP_REALT_THEGRAPH_GNOSIS ENV REACT_APP_REALT_THEGRAPH_RMM=$REACT_APP_REALT_THEGRAPH_RMM +ENV REACT_APP_REALT_THEGRAPH_ETH=$REACT_APP_REALT_THEGRAPH_ETH ENV GENERATE_SOURCEMAP=false RUN npm run build diff --git a/frontend/example.env b/frontend/example.env index 731d4ac..af2337b 100644 --- a/frontend/example.env +++ b/frontend/example.env @@ -1,4 +1,6 @@ REACT_APP_REALT_PROPERTIES_BACKEND_URL=http://localhost:3000/ -REACT_APP_REALT_THEGRAPH_URL=https://api.thegraph.com/subgraphs/name/realtoken-thegraph/ -REACT_APP_REALT_THEGRAPH_GNOSIS=realtoken-xdai -REACT_APP_REALT_THEGRAPH_RMM=rmm-v3-wrapper-gnosis \ No newline at end of file +REACT_APP_REALT_THEGRAPH_URL=https://gateway-arbitrum.network.thegraph.com/api/ +REACT_APP_REALT_THEGRAPH_API_KEY=YOUR_API_KEY_HERE +REACT_APP_REALT_THEGRAPH_RMM=subgraphs/id/9Ut97U2oMKwRucppj7fdMeZ8oFCJrUYyr8wu4hFXBn7Y +REACT_APP_REALT_THEGRAPH_GNOSIS=subgraphs/id/FPPoFB7S2dcCNrRyjM5QbaMwKqRZPdbTg8ysBrwXd4SP +REACT_APP_REALT_THEGRAPH_ETH=subgraphs/id/EVjGN4mMd9h9JfGR7yLC6T2xrJf9syhjQNboFb7GzxVW \ No newline at end of file