feat: add prod and dev jobs workflow #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Manually trigger an Azure Machine Learning job | |
on: [push] | |
permissions: | |
id-token: write | |
contents: read | |
jobs: | |
devtrain: | |
runs-on: ubuntu-latest | |
environment: dev | |
steps: | |
- name: Check out repo | |
uses: actions/checkout@main | |
- name: Install az ml extension | |
run: az extension add -n ml -y | |
- name: Azure login | |
uses: azure/login@v1 | |
with: | |
client-id: ${{ secrets.AZURE_CLIENT_ID }} | |
tenant-id: ${{ secrets.AZURE_TENANT_ID }} | |
subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }} | |
- name: Set defaults | |
run: az configure --defaults group=testshahzeb && az configure --defaults workspace=mlshah | |
- name: Run command | |
run: az ml job create --file src/job.yml --stream | |
prodtrain: | |
needs: devtrain | |
runs-on: ubuntu-latest | |
environment: prod | |
steps: | |
- name: Check out repo | |
uses: actions/checkout@main | |
- name: Install az ml extension | |
run: az extension add -n ml -y | |
- name: Azure login | |
uses: azure/login@v1 | |
with: | |
client-id: ${{ secrets.AZURE_CLIENT_ID }} | |
tenant-id: ${{ secrets.AZURE_TENANT_ID }} | |
subscription-id: ${{ secrets.AZURE_SUBSCRIPTION_ID }} | |
- name: Set defaults | |
run: az configure --defaults group=testshahzeb && az configure --defaults workspace=mlshah | |
- name: Run command | |
run: az ml job create --file src/prod_job.yml --stream | |