diff --git a/.github/workflows/demo-slack.yml b/.github/workflows/demo-slack.yml index 14cc5d3..ae0458d 100644 --- a/.github/workflows/demo-slack.yml +++ b/.github/workflows/demo-slack.yml @@ -1,9 +1,9 @@ name: Send custom JSON data to Slack workflow +# Tues @4am UTC on: - push: - branches: - - slack-demo + schedule: + - cron: "0 4 * * 2" jobs: build: @@ -16,10 +16,14 @@ jobs: uses: actions/setup-python@v1 - name: Install requirements - run: pip install -r requirements.txt + run: pip install -r ./telemetry-expiry/requirements.txt + # Temporary hard code project - name: Run telemetry probe expiry check - run: python ./check_metrics.py -p focus-ios + run: python ./telemetry-expiry/check_metrics.py -p focus-ios + + - name: Run telemetry probe expiry check + run: ls -la - name: Demo Slack Message id: slack diff --git a/check_metrics.ini b/telemetry-expiry/check_metrics.ini similarity index 100% rename from check_metrics.ini rename to telemetry-expiry/check_metrics.ini diff --git a/check_metrics.py b/telemetry-expiry/check_metrics.py similarity index 99% rename from check_metrics.py rename to telemetry-expiry/check_metrics.py index 43e77e0..be0a594 100644 --- a/check_metrics.py +++ b/telemetry-expiry/check_metrics.py @@ -15,7 +15,7 @@ import yaml -CONFIG_INI = 'check_metrics.ini' +CONFIG_INI = 'telemetry-expiry/check_metrics.ini' PAYLOAD_JSON = 'slack-payload.json' WARN_THRESHOLD_DAYS = 7 expired_already = [] diff --git a/telemetry-expiry/requirements.txt b/telemetry-expiry/requirements.txt new file mode 100644 index 0000000..be2b74d --- /dev/null +++ b/telemetry-expiry/requirements.txt @@ -0,0 +1 @@ +PyYAML==6.0.1