Skip to content

Commit

Permalink
Pin Ansible deps in requirements.txt
Browse files Browse the repository at this point in the history
  • Loading branch information
hatemosphere committed Nov 2, 2023
1 parent 6022210 commit 5ab938f
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 2 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/load_testing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,8 @@ jobs:

- name: Install Ansible
run: |
# to-do pin versions and move to requirements.yaml
python -m pip install --upgrade pip
pip install ansible ansible-core google-auth
pip install -r infrastructure/loadtests/ansible/requirements.txt
echo "/home/runner/.local/bin" >> $GITHUB_PATH
ansible-galaxy install -r infrastructure/loadtests/ansible/requirements.yml
Expand Down
11 changes: 11 additions & 0 deletions infrastructure/loadtests/ansible/extract.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# packages_to_extract.py
packages = {"ansible", "ansible-core", "google-auth"}

with open("requirements_all.txt", "r") as file:
lines = file.readlines()

with open("requirements.txt", "w") as file:
for line in lines:
pkg = line.split("==")[0]
if pkg in packages:
file.write(line)
3 changes: 3 additions & 0 deletions infrastructure/loadtests/ansible/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ansible==8.3.0
ansible-core==2.15.3
google-auth==2.19.1

0 comments on commit 5ab938f

Please sign in to comment.