Skip to content

Commit

Permalink
fix(ansible): bf2 telegraf needs special bind for temp
Browse files Browse the repository at this point in the history
Signed-off-by: Boris Glimcher <[email protected]>
  • Loading branch information
glimchb authored May 22, 2024
1 parent af0d816 commit 48d7aab
Showing 1 changed file with 26 additions and 4 deletions.
30 changes: 26 additions & 4 deletions lab/ansible/setup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,14 +96,36 @@
- name: Copy telegraf folder to remote
ansible.builtin.copy: src=../otel/telegraf.d dest=/root

- name: Run telegraf container on Nvidia BF
when: inventory_hostname == 'bf2'
community.docker.docker_container:
name: telegraf
image: docker.io/library/telegraf:1.29
state: started
restart: true
detach: true
network_mode: host
restart_policy: always
mounts:
- type: bind
source: /root/telegraf.d/telegraf.conf.bf2
target: /etc/telegraf/telegraf.conf
read_only: true
- type: bind
source: /run/emu_param
target: /run/emu_param
read_only: true

# TODO: copy correct telegraf.conf file per host...
#- name: Copy file to host
# ansible.builtin.copy: src=../otel/telegraf.d/telegraf.conf.{{ inventory_hostname }} dest=/root/telegraf.conf.new

# TODO: re-enable MEV

- name: Run telegraf container
when: inventory_hostname != 'mev'
- name: Run telegraf container on others
when:
- inventory_hostname != 'mev'
- inventory_hostname != 'bf2'
community.docker.docker_container:
name: telegraf
image: docker.io/library/telegraf:1.29
Expand All @@ -114,8 +136,8 @@
restart_policy: always
mounts:
- type: bind
source: /root/telegraf.conf
target: /etc/telegraf/telegraf.conf
source: /root/telegraf.d
target: /etc/telegraf/telegraf.d
read_only: true

- name:
Expand Down

0 comments on commit 48d7aab

Please sign in to comment.