lauberto is scraping files 🐧 #6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: GitHub Actions Demo | |
| run-name: ${{ github.actor }} is scraping files 🐧 | |
| on: | |
| # schedule: | |
| # - cron: '30 0 * * *' | |
| # - cron: '55 * * * *' | |
| workflow_dispatch: # Allows manual triggering | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| run-script: | |
| runs-on: [self-hosted, linux, x64] | |
| env: | |
| API_TOKEN: ${{ secrets.API_TOKEN }} | |
| API_BASE_URL: ${{ secrets.API_BASE_URL }} | |
| API_DEV_URL: ${{ secrets.API_DEV_URL }} | |
| HOST: ${{ secrets.HOST }} | |
| PORT: ${{ secrets.PORT }} | |
| SENDER: ${{ secrets.SENDER }} | |
| RECIPIENTS: ${{ secrets.RECIPIENTS }} | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 # Ensures you have access to the repo files | |
| - name: Set up Python | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.10' | |
| - name: Install Dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| if [ -f requirements.txt ]; then pip install -r requirements.txt; fi | |
| - name: Run Python Script | |
| run: python get_data.py # Replace with the actual script path |