-
Notifications
You must be signed in to change notification settings - Fork 14
55 lines (45 loc) · 1.64 KB
/
statistic-schedule.yml
File metadata and controls
55 lines (45 loc) · 1.64 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: Statistics Schedule
env:
DB_USER_NAME: ${{ secrets.STATS_DB_USER_NAME }}
DB_PASSWORD: ${{ secrets.STATS_DB_PASSWORD }}
DB_HOST_AND_PORT: ${{ secrets.STATS_DB_HOST_AND_PORT }}
DB_NAME: ${{ secrets.STATS_DB_NAME }}
on:
schedule:
- cron: "0 16 * * *"
push:
branches:
- "statistics/**"
- "dependabot/**"
workflow_dispatch:
jobs:
execute_job:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
job_name: [docker_pull_citus, github_clone_citus, homebrew_citus]
steps:
- name: Create GitHub App token
id: app
uses: actions/create-github-app-token@v1
with:
app-id: ${{ vars.GH_APP_ID }}
private-key: ${{ secrets.GH_APP_KEY }}
owner: ${{ github.repository_owner }}
- name: Set GH_TOKEN for all steps
run: echo "GH_TOKEN=${{ steps.app.outputs.token }}" >> $GITHUB_ENV
- name: Configure git with x-access-token
run: git config --global url."https://x-access-token:${{ steps.app.outputs.token }}@github.com/".insteadOf "https://github.com/"
- name: Checkout repository
uses: actions/checkout@v3
with:
token: ${{ steps.app.outputs.token }}
- name: Install package dependencies
run: sudo apt-get update && sudo apt-get install libcurl4-openssl-dev libssl-dev python3-testresources
- name: Install python requirements
run: python -m pip install -r packaging_automation/requirements.txt
- name: Execute 'Fetch Daily Statistics'
run: packaging_automation/bash/daily-statistics-job.sh
env:
JOB_NAME: "${{ matrix.JOB_NAME }}"