mirror of
https://github.com/darksaid98/cadence-discord-bot.git
synced 2026-12-02 14:38:49 +00:00
fix: update Dockerfile and CI/CD workflows
This commit is contained in:
1 parent
7185fe4071
commit
f21bfbae6f
5 files changed
+33
-22
No files matched your search
@@ -12,6 +12,17 @@ jobs:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Setup Docker Buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
|
||||
- name: Cache Docker layers
|
||||
uses: actions/cache@v2
|
||||
with:
|
||||
path: /tmp/.buildx-cache
|
||||
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-buildx-
|
||||
|
||||
- name: Login to DockerHub
|
||||
uses: docker/login-action@v1
|
||||
with:
|
||||
@@ -22,8 +33,10 @@ jobs:
|
||||
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
|
||||
|
||||
- name: Build and Push Docker Image
|
||||
run: |
|
||||
docker build -t mariusbegby/cadence:${{ env.RELEASE_VERSION }} .
|
||||
docker tag mariusbegby/cadence:${{ env.RELEASE_VERSION }} mariusbegby/cadence:latest
|
||||
docker push mariusbegby/cadence:${{ env.RELEASE_VERSION }}
|
||||
docker push mariusbegby/cadence:latest
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
tags: mariusbegby/cadence:${{ env.RELEASE_VERSION }}, mariusbegby/cadence:latest
|
||||
cache-from: type=local,src=/tmp/.buildx-cache
|
||||
cache-to: type=local,dest=/tmp/.buildx-cache
|
||||
@@ -26,5 +26,6 @@ jobs:
|
||||
node-version: ${{ matrix.node-version }}
|
||||
cache: 'npm'
|
||||
- run: npm install -g npm@latest
|
||||
- run: npm ci --legacy-peer-deps
|
||||
- run: npm ci
|
||||
- run: npm run eslint
|
||||
- run: npm run build
|
||||
Reference in new issue
Block a user