Skip to content

Merge remote-tracking branch 'origin/master' #1

Merge remote-tracking branch 'origin/master'

Merge remote-tracking branch 'origin/master' #1

Workflow file for this run

name: deploy to cloudflare workers
on:
push:
branches:
- master
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 'latest'
- name: github release
if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v1
with:
token: ${{ secrets.GH_TOKEN }}
publish:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 'latest'
- id: node-modules-cache
uses: actions/cache@v4
with:
path: |
node_modules
key: node-modules-${{ hashFiles('package-lock.json') }}
restore-keys: node-modules-
- name: cloudflare workers publish
uses: cloudflare/wrangler-action@v3
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
preCommands: |
[ -z "$SECRET_TELEGRAM_API_TOKEN" ] && echo "Secret SECRET_TELEGRAM_API_TOKEN not set, creating dummy one..." && SECRET_TELEGRAM_API_TOKEN="default-gh-action-secret" || true
secrets: |
SECRET_TELEGRAM_API_TOKEN
env:
SECRET_TELEGRAM_API_TOKEN: ${{ secrets.SECRET_TELEGRAM_API_TOKEN }}