Skip to content

Commit 0da956a

Browse files
refactor: pin system requirements to favor controlled updates (#30)
1 parent d857639 commit 0da956a

File tree

2 files changed

+21
-5
lines changed

2 files changed

+21
-5
lines changed

.github/workflows/build.yml

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,16 @@ on:
2424
required: false
2525
type: boolean
2626
default: true
27+
RUNNER_WORKFLOW_LABEL:
28+
description: 'The label of the runner workflow to run'
29+
required: false
30+
type: string
31+
default: 'ubuntu-24.04'
32+
PYTHON_VERSION:
33+
description: 'Python version to use for the workflow'
34+
required: false
35+
type: string
36+
default: '3.12'
2737
secrets:
2838
DOCKERHUB_USERNAME:
2939
description: 'DockerHub username for login'
@@ -46,7 +56,7 @@ on:
4656

4757
jobs:
4858
build:
49-
runs-on: ubuntu-latest
59+
runs-on: ${{ inputs.RUNNER_WORKFLOW_LABEL }}
5060
defaults:
5161
run:
5262
shell: bash
@@ -60,7 +70,7 @@ jobs:
6070
uses: actions/checkout@v4
6171
with:
6272
repository: edunext/picasso
63-
ref: main
73+
ref: v1
6474
path: picasso
6575

6676
- name: Checkout strains repository for build configurations
@@ -71,9 +81,15 @@ jobs:
7181
ssh-key: ${{ secrets.SSH_PRIVATE_KEY }}
7282
path: strains
7383

74-
- name: Install necessary dependencies
84+
- name: Setup Python
85+
uses: actions/setup-python@v5
86+
with:
87+
python-version: ${{ inputs.PYTHON_VERSION }}
88+
89+
- name: Install necessary requirements for workflow scripts
90+
working-directory: ${{ github.workspace }}
7591
run: |
76-
pip install pyyaml
92+
pip install -r picasso/requirements/base.txt
7793
7894
- name: Get Tutor Configurations from config.yml and set them as an environment variable
7995
working-directory: ${{ github.workspace }}
@@ -145,7 +161,6 @@ jobs:
145161
(tutor images build $SERVICE --no-cache 2>&1) | tee $LOGS_FILE_PATH
146162
147163
- name: Scan build logs for potential errors in the image
148-
working-directory: ${{ github.workspace }}
149164
env:
150165
SCRIPT_PATH: picasso/.github/workflows/scripts/identify_silent_errors.py
151166
LOGS_FILE_PATH: /tmp/build_logs.out

requirements/base.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
pyyaml

0 commit comments

Comments
 (0)