mirror of
https://github.com/KevinMidboe/playbooks-retailor.git
synced 2026-01-06 01:15:45 +00:00
ansible playbooks for retailor.io infrastructure
This commit is contained in:
12
roles/env/tasks/main.yml
vendored
Normal file
12
roles/env/tasks/main.yml
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
---
|
||||
- name: Read .env file
|
||||
ansible.builtin.slurp:
|
||||
src: "../.env"
|
||||
delegate_to: localhost
|
||||
register: env_file
|
||||
|
||||
- name: Parse .env file
|
||||
ansible.builtin.set_fact:
|
||||
env_vars: "{{ dict(env_file['content'] | b64decode | split('\n') | select('search', '=') | map('split', '=', 1) | list) }}"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user