refactor: update build pipeline
Some checks failed
Build BAB Application Deployment Artifact / build (push) Failing after 2m0s
Some checks failed
Build BAB Application Deployment Artifact / build (push) Failing after 2m0s
This commit is contained in:
@@ -30,26 +30,15 @@ jobs:
|
||||
- name: Show env file
|
||||
run: |
|
||||
/bin/cat .env.local
|
||||
- name: Build Project
|
||||
run: npm run build
|
||||
- name: Set VERSION from VERSION file
|
||||
id: get_version
|
||||
- name: Set GITEA_TOKEN variable
|
||||
run: echo "GITEA_TOKEN=${{ secrets.GT_TOKEN }}" >> $GITEA_ENV
|
||||
- name: Build and Release
|
||||
id: build
|
||||
run: |
|
||||
VERSION=$(cat VERSION)
|
||||
echo "VERSION=$VERSION"
|
||||
echo "::set-output name=VERSION::$VERSION"
|
||||
- name: Tarfile
|
||||
run: |
|
||||
cd dist/pwa
|
||||
tar czf ../../build-${{ steps.get_version.outputs.VERSION }}.tar.gz .
|
||||
- name: Upload Artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: build-artifact-${{ steps.get_version.outputs.VERSION }}.${{ gitea.run_number }}
|
||||
path: build-${{ steps.get_version.outputs.VERSION }}.tar.gz
|
||||
semantic-version
|
||||
- name: Trigger Ansible Deploy Playbook
|
||||
uses: https://github.com/distributhor/workflow-webhook@v3
|
||||
with:
|
||||
webhook_url: ${{ vars.WEBHOOK_URL }}
|
||||
verbose: true
|
||||
data: '{ "artifact_url": "${{ gitea.server_url }}/${{ gitea.repository }}/actions/runs/${{ gitea.run_id}}/artifacts/build-artifact-${{ steps.get_version.outputs.VERSION }}.${{ gitea.run_number }}" }'
|
||||
data: '{ "artifact_url": "${{ gitea.server_url }}/${{ gitea.repository }}/releases/download/${{ steps.build.outputs.VERSION }}/release-${{ steps.build.outputs.VERSION }}.tar.gz" }'
|
||||
|
||||
Reference in New Issue
Block a user