diff --git a/backend/Dockerfile b/backend/Dockerfile index 957bc6ab5..a67f14b8d 100644 --- a/backend/Dockerfile +++ b/backend/Dockerfile @@ -5,7 +5,7 @@ EXPOSE 4000 CMD ["yarn", "run", "start"] ARG BUILD_COMMIT ENV BUILD_COMMIT=$BUILD_COMMIT -ARG WORKDIR=/nitro-backend +ARG WORKDIR=/develop-backend RUN mkdir -p $WORKDIR WORKDIR $WORKDIR @@ -22,7 +22,7 @@ RUN NODE_ENV=production yarn run build # reduce image size with a multistage build FROM base as production ENV NODE_ENV=production -COPY --from=build-and-test /nitro-backend/dist ./dist +COPY --from=build-and-test /develop-backend/dist ./dist COPY ./public/img/ ./public/img/ COPY ./public/providers.json ./public/providers.json RUN yarn install --production=true --frozen-lockfile --non-interactive --no-cache diff --git a/deployment/helm/human-connection/templates/deployments/deployment-backend.yaml b/deployment/helm/human-connection/templates/deployments/deployment-backend.yaml index 33aa8a0e0..e3f75a44c 100644 --- a/deployment/helm/human-connection/templates/deployments/deployment-backend.yaml +++ b/deployment/helm/human-connection/templates/deployments/deployment-backend.yaml @@ -44,7 +44,7 @@ spec: terminationMessagePath: /dev/termination-log terminationMessagePolicy: File volumeMounts: - - mountPath: /nitro-backend/public/uploads + - mountPath: /develop-backend/public/uploads name: uploads dnsPolicy: ClusterFirst restartPolicy: Always diff --git a/deployment/helm/human-connection/values.yaml b/deployment/helm/human-connection/values.yaml index 4ffaa2a43..4418b7371 100644 --- a/deployment/helm/human-connection/values.yaml +++ b/deployment/helm/human-connection/values.yaml @@ -7,7 +7,7 @@ dbInitializion: "yarn prod:migrate init" # dbMigrations runs the database migrations in a post-upgrade hook. dbMigrations: "yarn prod:migrate up" # bakendImage is the docker image for the backend deployment -backendImage: ocelotsocialnetwork/nitro-backend +backendImage: ocelotsocialnetwork/develop-backend # maintenanceImage is the docker image for the maintenance deployment maintenanceImage: ocelotsocialnetwork/maintenance # neo4jImage is the docker image for the neo4j deployment diff --git a/deployment/human-connection/deployment-backend.yaml b/deployment/human-connection/deployment-backend.yaml index 3a0c25166..733fb2865 100644 --- a/deployment/human-connection/deployment-backend.yaml +++ b/deployment/human-connection/deployment-backend.yaml @@ -36,7 +36,7 @@ spec: name: configmap - secretRef: name: human-connection - image: ocelotsocialnetwork/nitro-backend:latest + image: ocelotsocialnetwork/develop-backend:latest imagePullPolicy: Always name: backend ports: @@ -46,7 +46,7 @@ spec: terminationMessagePath: /dev/termination-log terminationMessagePolicy: File volumeMounts: - - mountPath: /nitro-backend/public/uploads + - mountPath: /develop-backend/public/uploads name: uploads dnsPolicy: ClusterFirst restartPolicy: Always diff --git a/deployment/human-connection/templates/configmap.template.yaml b/deployment/human-connection/templates/configmap.template.yaml index ae093e4bd..e20f49e74 100644 --- a/deployment/human-connection/templates/configmap.template.yaml +++ b/deployment/human-connection/templates/configmap.template.yaml @@ -4,7 +4,7 @@ data: SMTP_HOST: "mailserver.human-connection" SMTP_PORT: "25" - GRAPHQL_URI: "http://nitro-backend.human-connection:4000" + GRAPHQL_URI: "http://develop-backend.human-connection:4000" NEO4J_URI: "bolt://nitro-neo4j.human-connection:7687" NEO4J_AUTH: "none" CLIENT_URI: "https://nitro-staging.human-connection.org" diff --git a/deployment/legacy-migration/README.md b/deployment/legacy-migration/README.md index 7cd1489ff..3a9f33a4a 100644 --- a/deployment/legacy-migration/README.md +++ b/deployment/legacy-migration/README.md @@ -43,13 +43,13 @@ Then temporarily delete backend and database deployments ```bash $ kubectl --namespace=human-connection get deployments NAME READY UP-TO-DATE AVAILABLE AGE -nitro-backend 1/1 1 1 3d11h +develop-backend 1/1 1 1 3d11h nitro-neo4j 1/1 1 1 3d11h develop-webapp 2/2 2 2 73d $ kubectl --namespace=human-connection delete deployment nitro-neo4j deployment.extensions "nitro-neo4j" deleted -$ kubectl --namespace=human-connection delete deployment nitro-backend -deployment.extensions "nitro-backend" deleted +$ kubectl --namespace=human-connection delete deployment develop-backend +deployment.extensions "develop-backend" deleted ``` Deploy one-time maintenance-worker pod: diff --git a/deployment/minikube/README.md b/deployment/minikube/README.md index d5103d66d..499fc8290 100644 --- a/deployment/minikube/README.md +++ b/deployment/minikube/README.md @@ -20,6 +20,6 @@ For example: ```text $ minikube service develop-webapp --namespace=human-connection # optionally -$ minikube service nitro-backend --namespace=human-connection +$ minikube service develop-backend --namespace=human-connection ``` diff --git a/deployment/volumes/README.md b/deployment/volumes/README.md index 2d08a34cb..10f0fd226 100644 --- a/deployment/volumes/README.md +++ b/deployment/volumes/README.md @@ -3,7 +3,7 @@ At the moment, the application needs two persistent volumes: * The `/data/` folder where `neo4j` stores its database and -* the folder `/nitro-backend/public/uploads` where the backend stores uploads. +* the folder `/develop-backend/public/uploads` where the backend stores uploads. As a matter of precaution, the persistent volume claims that setup these volumes live in a separate folder. You don't want to accidently loose all your data in diff --git a/deployment/volumes/velero/README.md b/deployment/volumes/velero/README.md index e469ad117..2ff31eece 100644 --- a/deployment/volumes/velero/README.md +++ b/deployment/volumes/velero/README.md @@ -65,7 +65,7 @@ You should see the persistent volumes at the end of the log: Restic Backups: Completed: - human-connection/nitro-backend-5b6dd96d6b-q77n6: uploads + human-connection/develop-backend-5b6dd96d6b-q77n6: uploads human-connection/nitro-neo4j-686d768598-z2vhh: neo4j-data ``` diff --git a/docker-compose.build-and-test.yml b/docker-compose.build-and-test.yml index 8796940b7..dbbb16d9b 100644 --- a/docker-compose.build-and-test.yml +++ b/docker-compose.build-and-test.yml @@ -11,7 +11,7 @@ services: backend: environment: - "CI=${CI}" - image: ocelotsocialnetwork/nitro-backend:build-and-test + image: ocelotsocialnetwork/develop-backend:build-and-test build: context: backend target: build-and-test diff --git a/docker-compose.override.yml b/docker-compose.override.yml index 31cd4da37..f2dec82dd 100644 --- a/docker-compose.override.yml +++ b/docker-compose.override.yml @@ -22,7 +22,7 @@ services: context: backend target: build-and-test volumes: - - ./backend:/nitro-backend + - ./backend:/develop-backend command: yarn run dev environment: - SMTP_HOST=mailserver diff --git a/docker-compose.yml b/docker-compose.yml index 228cf8be7..fa0e2591a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -22,7 +22,7 @@ services: - GRAPHQL_URI=http://backend:4000 - MAPBOX_TOKEN="pk.eyJ1IjoiaHVtYW4tY29ubmVjdGlvbiIsImEiOiJjajl0cnBubGoweTVlM3VwZ2lzNTNud3ZtIn0.bZ8KK9l70omjXbEkkbHGsQ" backend: - image: ocelotsocialnetwork/nitro-backend:latest + image: ocelotsocialnetwork/develop-backend:latest build: context: backend target: production @@ -35,8 +35,8 @@ services: ports: - 4000:4000 volumes: - - backend_node_modules:/nitro-backend/node_modules - - uploads:/nitro-backend/public/uploads + - backend_node_modules:/develop-backend/node_modules + - uploads:/develop-backend/public/uploads environment: - NEO4J_URI=bolt://neo4j:7687 - GRAPHQL_URI=http://backend:4000 diff --git a/scripts/docker_push.sh b/scripts/docker_push.sh index b417b3a39..37dde8fb7 100755 --- a/scripts/docker_push.sh +++ b/scripts/docker_push.sh @@ -4,11 +4,11 @@ ROOT_DIR=$(dirname "$0")/.. VERSION=$(jq -r '.version' $ROOT_DIR/package.json) IFS='.' read -r major minor patch <<< $VERSION -apps=(develop-webapp nitro-backend neo4j maintenance) +apps=(develop-webapp develop-backend neo4j maintenance) tags=($major $major.$minor $major.$minor.$patch) # These three docker images have already been built by now: -# docker build --build-arg BUILD_COMMIT=$BUILD_COMMIT --target production -t ocelotsocialnetwork/nitro-backend:latest $ROOT_DIR/backend +# docker build --build-arg BUILD_COMMIT=$BUILD_COMMIT --target production -t ocelotsocialnetwork/develop-backend:latest $ROOT_DIR/backend # docker build --build-arg BUILD_COMMIT=$BUILD_COMMIT --target production -t ocelotsocialnetwork/develop-webapp:latest $ROOT_DIR/webapp # docker build --build-arg BUILD_COMMIT=$BUILD_COMMIT -t ocelotsocialnetwork/neo4j:latest $ROOT_DIR/neo4j docker build -t ocelotsocialnetwork/maintenance:latest $ROOT_DIR/webapp/ -f $ROOT_DIR/webapp/Dockerfile.maintenance