diff --git a/.github/workflows/dockerimage.yml b/.github/workflows/dockerimage.yml index 959117ba..ea135215 100644 --- a/.github/workflows/dockerimage.yml +++ b/.github/workflows/dockerimage.yml @@ -27,4 +27,4 @@ jobs: run: gcloud auth configure-docker --quiet - name: Build Docker image - run: docker build . --file fast.Dockerfile -t $IMAGE_NAME + run: docker build . --file fasttest.Dockerfile -t $IMAGE_NAME diff --git a/.github/workflows/quasar_deploy.yml b/.github/workflows/quasar_deploy.yml index dfe3d255..e9a8d7be 100644 --- a/.github/workflows/quasar_deploy.yml +++ b/.github/workflows/quasar_deploy.yml @@ -121,7 +121,7 @@ jobs: target: poc channelId: live entryPoint: ./client - deploy_backend: + release_backend: name: Build and test backend runs-on: ubuntu-latest needs: [ pre_check ] @@ -148,20 +148,20 @@ jobs: - name: Push Docker image run: docker push $IMAGE_NAME + deploy_backend: + name: Deploy backend + runs-on: ubuntu-latest + needs: [ release_backend ] + strategy: + matrix: + server: [ "quotes", "appserver" ] + steps: + - name: Release ${{ matrix.server }} server + run: |- + gcloud run deploy ${{ matrix.server }} \ + --region asia-northeast1 \ + --image gcr.io/gainstrack/gainstrack \ + --platform managed \ + --allow-unauthenticated \ + --project gainstrack - - name: Release quotes server - run: |- - gcloud run deploy quotes \ - --region asia-northeast1 \ - --image gcr.io/gainstrack/gainstrack \ - --platform managed \ - --allow-unauthenticated \ - --project gainstrack - - name: Release appserver server - run: |- - gcloud run deploy appserver \ - --region asia-northeast1 \ - --image gcr.io/gainstrack/gainstrack \ - --platform managed \ - --allow-unauthenticated \ - --project gainstrack diff --git a/.github/workflows/runtimebase.yml b/.github/workflows/runtimebase.yml index d8ce0113..61480ccb 100644 --- a/.github/workflows/runtimebase.yml +++ b/.github/workflows/runtimebase.yml @@ -23,7 +23,7 @@ jobs: run: gcloud auth configure-docker --quiet - name: Build Docker image - run: docker build . --file scalabase.Dockerfile -t $IMAGE_NAME + run: docker build . --file runtime.Dockerfile -t $IMAGE_NAME - name: Push Docker image run: docker push $IMAGE_NAME diff --git a/fast.Dockerfile b/fast.Dockerfile index c445dd7e..629ed662 100644 --- a/fast.Dockerfile +++ b/fast.Dockerfile @@ -6,7 +6,7 @@ COPY build.sbt . COPY web web COPY quotes quotes COPY core core -RUN sbt test assembly +RUN sbt assembly FROM gcr.io/gainstrack/runtime RUN mkdir -p /app diff --git a/fasttest.Dockerfile b/fasttest.Dockerfile new file mode 100644 index 00000000..b3cfb4b2 --- /dev/null +++ b/fasttest.Dockerfile @@ -0,0 +1,8 @@ +FROM gcr.io/gainstrack/scalabase as builder +WORKDIR /build +COPY project project +COPY build.sbt . +COPY web web +COPY quotes quotes +COPY core core +RUN sbt test assembly