We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If you want to create a base GitHub action files and run it with different settings, you can do this using reusable calls as follows
# modular_workflow_file.yaml name: Modular Workflow File using flag1 on: workflow_call: inputs: flag1: required: true type: boolean env: ENV_VAR1: ${{ secrets.ENV_VAR1 }} ENV_VAR2: ${{ secrets.ENV_VAR2 }} jobs: my_job_name: runs-on: ubuntu-latest steps: - name: Clone repo uses: actions/checkout@v3 - name: Set up environment uses: actions/setup-python@v4 with: python-version: "3.10" - name: Install pip requirements run: pip install uv && uv pip install -e . --system - name: Run file run: | echo "Running with --flag1=${{ inputs.flag1}}" python my_lib/folder1/script1 --flag1=${{ inputs.flag1}}
# calling workflow file name: Workflow using settings True on: schedule: - cron: "0 0 * * *" # Runs every day at midnight workflow_dispatch: concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true jobs: call_reusable: uses: ./.github/workflows/modular_workflow_file.yaml with: flag1: True secrets: inherit # Passes all secrets to the reusable workflow
The text was updated successfully, but these errors were encountered:
No branches or pull requests
If you want to create a base GitHub action files and run it with different settings, you can do this using reusable calls as follows
The text was updated successfully, but these errors were encountered: