Commit cf2a89de authored by Pietsch, Martin's avatar Pietsch, Martin

add jailname variable to container structure

parent da32f3b4
---
- set_fact:
container: >-
{% do container.update({'jailname': container.name | replace('.', '_')}) -%}
{{ container }}
when: container is defined
- set_fact:
fuprm: ""
......@@ -8,15 +13,17 @@
- block:
- jail:
name: "{{ container.name }}"
name: "{{ container.jailname }}"
state: state
register: cstate
- debug:
var: cstate
- set_fact:
fuprm: "{{ '-b %s' | format(cstate.path) }}"
- set_fact:
puprm: "{{ '-j %s' | format(container.name) }}"
puprm: "{{ '-j %s' | format(container.jailname) }}"
when: container is defined
- name: fetch system updates
......@@ -54,7 +61,7 @@
- set_fact:
upgraded: "{{ upgraded | combine({ container.name: us}) }}"
- jail:
name: "{{ container.name }}"
name: "{{ container.jailname }}"
state: restart
when: upgraded[container.name] == True and upgraded["host"] == False
when: container is defined
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment