From 1697611d1c223fda0ac491746ad99dfdd28cf68d Mon Sep 17 00:00:00 2001 From: Joshua Winkler Date: Wed, 28 Feb 2024 12:58:06 +0100 Subject: [PATCH] new build --- .github/workflows/main.yml | 3 --- server/Dockerfile => Dockerfile | 6 +++--- 2 files changed, 3 insertions(+), 6 deletions(-) rename server/Dockerfile => Dockerfile (88%) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ab5ae56..6ca673d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -15,9 +15,6 @@ jobs: DOCKER_PASS: ${{ secrets.DOCKER_PASS }} run: | docker login https://docker.pkg.github.com -u $DOCKER_USER -p $DOCKER_PASS - - name: server dir - run: | - cd server - name: docker build run: | docker build . -t docker.pkg.github.com/josholaus/doofus-rick/bot:latest diff --git a/server/Dockerfile b/Dockerfile similarity index 88% rename from server/Dockerfile rename to Dockerfile index 8500371..4431797 100644 --- a/server/Dockerfile +++ b/Dockerfile @@ -5,17 +5,17 @@ WORKDIR /home/app # This will chache required dependencies and thus speed up future builds. FROM base AS install RUN mkdir -p /temp/dev -COPY package.json bun.lockb /temp/dev/ +COPY server/package.json server/bun.lockb /temp/dev/ RUN cd /temp/dev && bun install --frozen-lockfile # Install with --production flag to exclude development dependencies. RUN mkdir -p /temp/prod -COPY package.json bun.lockb /temp/prod/ +COPY server/package.json server/bun.lockb /temp/prod/ RUN cd /temp/prod && bun install --frozen-lockfile --production # Copy node_modules from temporary directory and all other non-ignored project files into the image. FROM base AS pre-release -COPY . . +COPY server . # Build ENV NODE_ENV=production