Skip to content

Cron Action

Cron Action #13779

Workflow file for this run

name: Cron Action
on:
workflow_dispatch:
schedule:
- cron: '0 */1 * * *'
jobs:
rss2telegram:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Download artifact
id: download
continue-on-error: true
uses: dawidd6/action-download-artifact@v2
with:
workflow: cron.yml
workflow_conclusion: success
- name: Move database
continue-on-error: true
run: mv rss2telegram/rss2telegram.db rss2telegram.db
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.8'
- name: Install Requirements
run: pip install -r requirements.txt
- name: Run Rss to Telegram
run: python rss2telegram.py
env:
BOT_TOKEN: ${{ secrets.BOT_TOKEN }}
DESTINATION: ${{ vars.DESTINATION }}
URL: ${{ vars.URL }}
EMOJIS: ${{ vars.EMOJIS }}
MESSAGE_TEMPLATE: ${{ vars.MESSAGE_TEMPLATE }}
BUTTON_TEXT: ${{ vars.BUTTON_TEXT }}
PARAMETERS: ${{ vars.PARAMETERS }}
DRYRUN: ${{ steps.download.outcome }}
- name: Upload history
uses: actions/upload-artifact@v3
with:
name: rss2telegram
path: rss2telegram.db