Skip to content

PROD - Sync Analytics Algolia #273

PROD - Sync Analytics Algolia

PROD - Sync Analytics Algolia #273

name: PROD - Sync Analytics Algolia
on:
schedule:
- cron: '0 6 * * *' # At 06:00 UTC, everyday.
workflow_dispatch:
jobs:
setup:
runs-on: ubuntu-latest
container:
image: ghcr.io/yldio/asap-hub/node-python-sq:86a189edc900d4e1afdcf3935c697292f69d409b
credentials:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
environment: Production
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup
id: setup
uses: ./.github/actions/setup-environment
with:
environment-name: Production
sync-crn-analytics-algolia:
uses: ./.github/workflows/reusable-crn-analytics-algolia-sync.yml
with:
contentful-environment-id: Production
environment-name: Production
metric: all
secrets:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
CRN_CONTENTFUL_ACCESS_TOKEN: ${{ secrets.CRN_CONTENTFUL_ACCESS_TOKEN }}
CONTENTFUL_MANAGEMENT_TOKEN: ${{ secrets.CONTENTFUL_MANAGEMENT_TOKEN }}
notify_failure:
runs-on: ubuntu-latest
needs: [sync-crn-analytics-algolia]
if: ${{ failure()}}
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: ./.github/actions/slack/
with:
message: CRN Algolia Prod Sync
webhook: ${{ secrets.SLACK_WEBHOOK }}
status: failure