Skip to content

Commit

Permalink
Fix Ansible tasks for PR CI fails
Browse files Browse the repository at this point in the history
  • Loading branch information
oguzkaganozt committed Jan 31, 2024
1 parent 2bdfe45 commit 00dcd04
Show file tree
Hide file tree
Showing 9 changed files with 26 additions and 38 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-main-self-hosted.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:

- name: Run setup script
run: |
./setup-dev-env.sh -y
./setup-dev-env.sh -y --module all --no-cuda-drivers openadk

Check warning on line 22 in .github/workflows/build-main-self-hosted.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (openadk)
- name: Set git config
uses: autowarefoundation/autoware-github-actions/set-git-config@v1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:

- name: Run setup script
run: |
./setup-dev-env.sh -y
./setup-dev-env.sh -y --module all --no-cuda-drivers openadk

Check warning on line 22 in .github/workflows/build-main.yaml

View workflow job for this annotation

GitHub Actions / spell-check-differential

Unknown word (openadk)
- name: Set git config
uses: autowarefoundation/autoware-github-actions/set-git-config@v1
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/setup-docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ jobs:
setup-docker:
needs: load-env
runs-on: ubuntu-latest
container: ${{ needs.load-env.outputs.base-image }}
steps:
- name: Check out repository
uses: actions/checkout@v4
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/setup-universe.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ jobs:
setup-universe:
needs: load-env
runs-on: ubuntu-latest
container: ${{ needs.load-env.outputs.base-image }}
steps:
- name: Check out repository
uses: actions/checkout@v4
Expand Down
26 changes: 13 additions & 13 deletions ansible/roles/cuda/tasks/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,61 +83,61 @@
- name: Create Vulkan directory
become: true
ansible.builtin.file:
path: "/etc/vulkan/icd.d"
path: /etc/vulkan/icd.d
state: directory
mode: "0755"

- name: Create OpenGL directory
become: true
ansible.builtin.file:
path: "/etc/glvnd/egl_vendor.d"
path: /etc/glvnd/egl_vendor.d
state: directory
mode: "0755"

- name: Create OpenCL directory
become: true
ansible.builtin.file:
path: "/etc/OpenCL/vendors"
path: /etc/OpenCL/vendors
state: directory
mode: "0755"

- name: Register Vulkan GPU vendors
become: true
ansible.builtin.get_url:
url: "https://gitlab.com/nvidia/container-images/vulkan/raw/dc389b0445c788901fda1d85be96fd1cb9410164/nvidia_icd.json"
dest: "/etc/vulkan/icd.d/nvidia_icd.json"
url: https://gitlab.com/nvidia/container-images/vulkan/raw/dc389b0445c788901fda1d85be96fd1cb9410164/nvidia_icd.json
dest: /etc/vulkan/icd.d/nvidia_icd.json
mode: "0644"

- name: Set permissions for Vulkan GPU vendors
become: true
ansible.builtin.file:
path: "/etc/vulkan/icd.d/nvidia_icd.json"
path: /etc/vulkan/icd.d/nvidia_icd.json
mode: "0644"

- name: Register OpenGL GPU vendors
become: true
ansible.builtin.get_url:
url: "https://gitlab.com/nvidia/container-images/opengl/raw/5191cf205d3e4bb1150091f9464499b076104354/glvnd/runtime/10_nvidia.json"
dest: "/etc/glvnd/egl_vendor.d/10_nvidia.json"
url: https://gitlab.com/nvidia/container-images/opengl/raw/5191cf205d3e4bb1150091f9464499b076104354/glvnd/runtime/10_nvidia.json
dest: /etc/glvnd/egl_vendor.d/10_nvidia.json
mode: "0644"

- name: Set permissions for OpenGL GPU vendors
become: true
ansible.builtin.file:
path: "/etc/glvnd/egl_vendor.d/10_nvidia.json"
path: /etc/glvnd/egl_vendor.d/10_nvidia.json
mode: "0644"

- name: Register OpenCL GPU vendors
become: true
ansible.builtin.file:
path: "/etc/OpenCL/vendors/nvidia.icd"
state: "touch"
path: /etc/OpenCL/vendors/nvidia.icd
state: touch
mode: "0644"

- name: Set permissions for OpenCL GPU vendors
become: true
ansible.builtin.lineinfile:
path: "/etc/OpenCL/vendors/nvidia.icd"
line: "libnvidia-opencl.so.1"
path: /etc/OpenCL/vendors/nvidia.icd
line: libnvidia-opencl.so.1
create: true
mode: "0644"
7 changes: 0 additions & 7 deletions ansible/roles/geographiclib/tasks/main.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
- name: Install libqt5charts5-dev # remove this task after merging https://github.com/ros/rosdistro/pull/39705.
become: true
ansible.builtin.apt:
name: libqt5charts5-dev
state: latest
update_cache: true

- name: Install geographiclib-tools
become: true
ansible.builtin.apt:
Expand Down
20 changes: 9 additions & 11 deletions ansible/roles/nvidia_docker/tasks/main.yaml
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
# tasks file for nvidia-container-toolkit-installation
- name: Add NVIDIA container toolkit GPG key
become: true
ansible.builtin.shell: |
curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg
ansible.builtin.apt_key:
url: https://nvidia.github.io/libnvidia-container/gpgkey
state: present
keyring: /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg

- name: Add NVIDIA container toolkit repository
become: true
ansible.builtin.shell: |
curl -s -L https://nvidia.github.io/libnvidia-container/stable/deb/nvidia-container-toolkit.list | \
sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
tee /etc/apt/sources.list.d/nvidia-container-toolkit.list
- name: Update apt cache
become: true
ansible.builtin.apt:
ansible.builtin.apt_repository:
repo: "deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://nvidia.github.io/libnvidia-container/stable/deb/ {{ ansible_distribution_release }} {{ ansible_architecture }}"

Check failure on line 11 in ansible/roles/nvidia_docker/tasks/main.yaml

View workflow job for this annotation

GitHub Actions / pre-commit-ansible

yaml[quoted-strings]

String value is redundantly quoted with any quotes
state: present
filename: nvidia-container-toolkit
update_cache: yes

Check failure on line 14 in ansible/roles/nvidia_docker/tasks/main.yaml

View workflow job for this annotation

GitHub Actions / pre-commit-ansible

yaml[truthy]

Truthy value should be one of \[false, true]

- name: Install NVIDIA Container Toolkit
Expand All @@ -27,3 +24,4 @@
become: true
ansible.builtin.shell: |
nvidia-ctk runtime configure --runtime=docker
changed_when: true
1 change: 0 additions & 1 deletion ansible/roles/tensorrt/defaults/main.yaml
Original file line number Diff line number Diff line change
@@ -1 +0,0 @@
install_devel: true
4 changes: 2 additions & 2 deletions ansible/roles/tensorrt/tasks/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
allow_change_held_packages: true
allow_downgrade: true
update_cache: true
when: install_devel | bool
when: install_devel == 'true'

# apt-mark hold
- name: Prevent CUDA-related packages from upgrading
Expand All @@ -49,4 +49,4 @@
- libnvinfer-plugin-dev
- libnvparsers-dev
- libnvonnxparsers-dev
when: install_devel | bool
when: install_devel == 'true'

0 comments on commit 00dcd04

Please sign in to comment.