Luigi Toscano | 6fba3fd | 2020-08-18 22:29:49 +0200 | [diff] [blame^] | 1 | - when: openrc_enable_export |
2 | block: | ||||
3 | - name: Extract the OS_ environment variables | ||||
4 | shell: | ||||
5 | cmd: | | ||||
6 | source {{ openrc_file }} {{ openrc_user }} {{ openrc_project }} &>/dev/null | ||||
7 | env | awk -F= 'BEGIN {print "---" } /^OS_/ { print " "$1": \""$2"\""} ' | ||||
8 | args: | ||||
9 | executable: "/bin/bash" | ||||
10 | register: env_os | ||||
11 | |||||
12 | - name: Save the OS_ environment variables as a fact | ||||
13 | set_fact: | ||||
14 | os_env_vars: "{{ env_os.stdout|from_yaml }}" |