Skip to content

Run post_to_all Script #238

Run post_to_all Script

Run post_to_all Script #238

Workflow file for this run

name: Run post_to_all Script
on:
schedule:
# Run at 1:30 AM, 7:00 AM, and 1:30 PM UTC (7:00, 12:30, 19:00 IST)
- cron: "30 1 * * *"
- cron: "0 7 * * *"
- cron: "30 13 * * *"
jobs:
run-post-to-all:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.11.9"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
# Log before running the script
- name: Log environment variables
run: printenv # Prints the environment variables to see if they are correctly set
- name: Log current directory
run: pwd # Print the current directory to ensure the correct working directory
- name: List files in directory
run: ls -al # List all files and directories to confirm your script is in the right place
- name: Run post_to_all.py script
run: |
echo "Running post_to_all.py..."
python post_to_all.py # Add this step to run your script
env:
MONGO_URI: ${{ secrets.MONGO_URI }}