name: Upgrade Python Requirements

on:
  schedule:
    - cron: "15 15 2,16 * *"
  workflow_dispatch:
    inputs:
      branch:
        description: "Target branch against which to create requirements PR"
        required: true
        default: 'master'

jobs:
  call-upgrade-python-requirements-workflow:
    uses: openedx/.github/.github/workflows/upgrade-python-requirements.yml@master
    with:
      branch: ${{ github.event.inputs.branch || 'master' }}
      # optional parameters below; fill in if you'd like github or email notifications
      # user_reviewers: ""
      # team_reviewers: ""
      email_address: "cosmonauts-requirements-update@2u-internal.opsgenie.net"
      send_success_notification: true
    secrets:
      requirements_bot_github_token: ${{ secrets.REQUIREMENTS_BOT_GITHUB_TOKEN }}
      requirements_bot_github_email: ${{ secrets.REQUIREMENTS_BOT_GITHUB_EMAIL }}
      edx_smtp_username: ${{ secrets.EDX_SMTP_USERNAME }}
      edx_smtp_password: ${{ secrets.EDX_SMTP_PASSWORD }}