Merge pull request #94 from HideyoshiSolutions/hotfix/conserta-deploy
hotfix: fixes deploy environment
This commit is contained in:
23
.github/workflows/deploy.yml
vendored
23
.github/workflows/deploy.yml
vendored
@@ -68,19 +68,24 @@ jobs:
|
||||
echo "IMAGE_LATEST=${IMAGE_BASE}:${TAG}" >> $GITHUB_ENV
|
||||
echo "IMAGE_SHA=${IMAGE_BASE}:sha-${SHORT_SHA}" >> $GITHUB_ENV
|
||||
|
||||
- name: Build Docker image
|
||||
run: |
|
||||
docker build -t $IMAGE_LATEST -t $IMAGE_SHA .
|
||||
|
||||
- name: Push Docker images
|
||||
run: |
|
||||
docker push $IMAGE_LATEST
|
||||
docker push $IMAGE_SHA
|
||||
- name: Build and push Docker image (with registry cache)
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: .
|
||||
push: true
|
||||
tags: |
|
||||
${{ env.IMAGE_LATEST }}
|
||||
${{ env.IMAGE_SHA }}
|
||||
cache-from: type=registry,ref=${{ env.IMAGE_LATEST }}
|
||||
cache-to: type=inline
|
||||
build-args: |
|
||||
BUILDKIT_INLINE_CACHE=1
|
||||
|
||||
deploy:
|
||||
needs: [docker]
|
||||
runs-on: ubuntu-latest
|
||||
environment: ${{ github.ref_name == 'main' && 'production' || 'development' }}
|
||||
environment:
|
||||
name: ${{ github.ref_name == 'main' && 'production' || 'development' }}
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
Reference in New Issue
Block a user