Update .gitea/workflows/main.yml
All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 6m40s
All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 6m40s
This commit is contained in:
parent
650fb019c2
commit
39efee7c7b
@ -15,6 +15,14 @@ jobs:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Set up Node.js
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: '20'
|
||||
|
||||
- name: Install pnpm
|
||||
run: npm install -g pnpm
|
||||
|
||||
- name: Set up Docker
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
@ -28,12 +36,12 @@ jobs:
|
||||
uses: docker/metadata-action@v5
|
||||
id: meta
|
||||
with:
|
||||
images: vontainment/v-firecrawl
|
||||
images: vontainment/v-gpt-node-app
|
||||
flavor: latest=false
|
||||
tags: |
|
||||
type=raw,value=main,enable=${{ gitea.ref == 'refs/heads/main' }}
|
||||
type=raw,value=dev,enable=${{ gitea.ref == 'refs/heads/dev' }}
|
||||
type=sha,priority=100,enable=${{ gitea.event_name == 'push' }}
|
||||
type=raw,value=main,enable=${{ github.ref == 'refs/heads/main' }}
|
||||
type=raw,value=dev,enable=${{ github.ref == 'refs/heads/dev' }}
|
||||
type=sha,priority=100,enable=${{ github.event_name == 'push' }}
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@v5
|
||||
@ -43,10 +51,3 @@ jobs:
|
||||
push: true
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
cache-from: type=local,src=/opt/hostedtoolcache/${{ gitea.repository }}-${{ gitea.ref_name }}/build/
|
||||
cache-to: type=local,dest=/opt/hostedtoolcache/${{ gitea.repository }}-${{ gitea.ref_name }}/build-new/
|
||||
|
||||
- name: Rotate build cache
|
||||
run: |
|
||||
rm -rf /opt/hostedtoolcache/${{ gitea.repository }}-${{ gitea.ref_name }}/build/
|
||||
mv /opt/hostedtoolcache/${{ gitea.repository }}-${{ gitea.ref_name }}/build-new/ /opt/hostedtoolcache/${{ gitea.repository }}-${{ gitea.ref_name }}/build/
|
||||
|
Loading…
Reference in New Issue
Block a user