Log Generator #67
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: Log Generator | |
| on: | |
| schedule: | |
| # Run every 5 minutes | |
| - cron: '*/5 * * * *' | |
| workflow_dispatch: # Manual trigger button | |
| jobs: | |
| generate-logs: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v3 | |
| - name: Setup Go | |
| uses: actions/setup-go@v4 | |
| with: | |
| go-version: '1.23' | |
| - name: Generate logs | |
| env: | |
| LOG_API_URL: ${{ secrets.LOG_API_URL }} | |
| CI: true | |
| run: | | |
| echo "Starting log generator..." | |
| echo "Target: $LOG_API_URL" | |
| # Build generator | |
| go build -o generator ./cmd/generator | |
| # Run for 4 minutes (leave 1 min buffer) | |
| timeout 240 ./generator || true | |
| echo "Log generation complete" |