diff --git a/docker/src.Dockerfile.dev b/deploy/dev/Dockerfile similarity index 100% rename from docker/src.Dockerfile.dev rename to deploy/dev/Dockerfile diff --git a/docker/Dockerfile b/deploy/docker/Dockerfile similarity index 100% rename from docker/Dockerfile rename to deploy/docker/Dockerfile diff --git a/docker/README.md b/deploy/docker/README.md similarity index 100% rename from docker/README.md rename to deploy/docker/README.md diff --git a/docker/docker-compose.yml b/deploy/docker/docker-compose.yml similarity index 100% rename from docker/docker-compose.yml rename to deploy/docker/docker-compose.yml diff --git a/docker/package.json b/deploy/docker/package.json similarity index 100% rename from docker/package.json rename to deploy/docker/package.json diff --git a/docker/steedos.config.js b/deploy/docker/steedos.config.js similarity index 100% rename from docker/steedos.config.js rename to deploy/docker/steedos.config.js diff --git a/deploy/try/Dockerfile b/deploy/try/Dockerfile new file mode 100644 index 0000000000..149736e177 --- /dev/null +++ b/deploy/try/Dockerfile @@ -0,0 +1,17 @@ +FROM steedos/steedos-community:latest + + +# Install MongoDB 4.4 +# https://www.mongodb.com/docs/v4.4/tutorial/install-mongodb-on-debian/ +RUN sudo apt-get update \ + && sudo apt-get install gnupg curl + +RUN curl -fsSL https://pgp.mongodb.com/server-4.4.asc | \ + sudo gpg -o /usr/share/keyrings/mongodb-server-4.4.gpg \ + --dearmor + +RUN echo "deb [ signed-by=/usr/share/keyrings/mongodb-server-4.4.gpg ] http://repo.mongodb.org/apt/debian buster/mongodb-org/4.4 main" | sudo tee /etc/apt/sources.list.d/mongodb-org-4.4.list + +RUN sudo apt-get update \ + && sudo apt-get install -y mongodb-org=4.4.24 mongodb-org-server=4.4.24 mongodb-org-shell=4.4.24 mongodb-org-mongos=4.4.24 mongodb-org-tools=4.4.24 + diff --git a/docker-compose.yml b/docker-compose.yml index b00fdebcbe..5df72452ab 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -5,7 +5,7 @@ services: steedos: build: context: ./ - dockerfile: ./docker/src.Dockerfile.dev + dockerfile: ./deploy/dev/Dockerfile image: steedos/steedos-community:dev ports: - "6000:6000" diff --git a/docker/src.Dockerfile.prod b/docker/src.Dockerfile.prod deleted file mode 100644 index 051f0452a5..0000000000 --- a/docker/src.Dockerfile.prod +++ /dev/null @@ -1,44 +0,0 @@ -FROM node:14-slim AS builder - -RUN apt-get update || : && apt-get install -y \ - python \ - curl \ - build-essential - -WORKDIR /app - -COPY ./.env ./ -COPY ./lerna.json ./ -COPY ./package.json ./ -COPY ./steedos.config.js ./ -COPY ./yarn.lock ./ -COPY ./.yarnclean ./.yarnclean -COPY ./packages ./packages -COPY ./server ./packages/server -COPY ./services ./services -COPY ./steedos-packages ./services -COPY ./ee ./services - -RUN yarn -RUN yarn run build -RUN yarn autoclean -RUN yarn lerna clean --yes - -FROM node:14-slim - -ENV NODE_ENV=production -ENV NODE_OPTIONS="--max-old-space-size=4096" - -WORKDIR /app - -COPY --from=builder ./app/.env ./ -COPY --from=builder ./app/lerna.json ./ -COPY --from=builder ./app/package.json ./ -COPY --from=builder ./app/steedos.config.js ./ -COPY --from=builder /app/packages ./packages -COPY --from=builder /app/services ./services - -RUN yarn --production -RUN yarn cache clean - -CMD ["yarn", "start"]