Skip to content

fix: implemented changes regarding #1 #47

fix: implemented changes regarding #1

fix: implemented changes regarding #1 #47

Workflow file for this run

name: Nightly Build
on:
push:
branches: [main]
release:
types:
- created
jobs:
build_and_upload:
runs-on: ubuntu-20.04
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Install pnpm
run: npm install -g pnpm
- name: Install dependencies
run: pnpm i
- name: Install lame
run: sudo apt-get install lame -y
- name: Build
run: pnpm build
- name: Creating config
env:
TEST_CONFIG: ${{ secrets.TEST_CONFIG }}
run: |
echo "$TEST_CONFIG" > dist/config.json
cp dist/config.json dist/pkg/config.json
- name: Run tests
run: pnpm test
- name: Remove config
if: always()
run: |
rm dist/config.json
rm dist/pkg/config.json
- name: Upload assets
if: always()
uses: actions/upload-artifact@v2
with:
name: dist
path: dist
retention-days: 7
- name: Upload release assets
if: github.event_name == 'release'
env:
GH_TOKEN: ${{ github.token }}
run: |
gh release upload "${{ github.event.release.tag_name }}" dist/pkg/freepbx-aws-polly-x64
gh release upload "${{ github.event.release.tag_name }}" dist/pkg/freepbx-aws-polly-arm64