diff --git a/Dockerfile b/Dockerfile index ad0a6eb..3b663f3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,12 +1,13 @@ ARG ENV=production -ARG MONGO_VERSION=latest +ARG MONGO_VERSION ARG PORT=9001 -ARG NPM_TOKEN=not_set +ARG NPM_TOKEN ARG YARN_VERSION=3.5.0 ## mongo build stage -FROM mongo:$MONGO_VERSION AS database -COPY docker-entrypoint-initdb.d/mongo-init-$MONGO_VERSION.sh ./docker-entrypoint-initdb.d/mongo-init.sh +FROM mongo:${MONGO_VERSION:-latest} AS database +ENV NODE_ENV $ENV +COPY docker-entrypoint-initdb.d/mongo-init-${MONGO_VERSION:-latest}.sh ./docker-entrypoint-initdb.d/mongo-init.sh ## stage one, build the service FROM node:20-bullseye-slim AS build diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index 2806a90..aca26c6 100644 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -8,7 +8,7 @@ services: context: . target: database args: - MONGO_VERSION: 6.0.5 + MONGO_VERSION: latest ports: - 27017:27017 networks: diff --git a/docker-entrypoint-initdb.d/mongo-init-6.0.5.sh b/docker-entrypoint-initdb.d/mongo-init-latest.sh similarity index 100% rename from docker-entrypoint-initdb.d/mongo-init-6.0.5.sh rename to docker-entrypoint-initdb.d/mongo-init-latest.sh diff --git a/package.json b/package.json index 1c3fbd3..056a286 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@mifi/auth-service", - "version": "1.0.3", + "version": "1.0.4", "author": "mifi (Mike Fitzpatrick)", "license": "MIT", "scripts": {