Skip to content
Snippets Groups Projects
Commit 74ae0158 authored by Martin van Es's avatar Martin van Es
Browse files

WIP

parent a26bd66e
No related branches found
No related tags found
Loading
...@@ -33,5 +33,12 @@ with open(f"{sys.argv[1]}.yaml", "r") as yaml_doc: ...@@ -33,5 +33,12 @@ with open(f"{sys.argv[1]}.yaml", "r") as yaml_doc:
except KeyError: except KeyError:
new_config['data'][host] = {record: [address_config]} new_config['data'][host] = {record: [address_config]}
try:
with open("revision", "r") as r:
revision = r.read().strip()
new_config['data']['']['txt'] = [{ 'txt': f'{revision}' }]
except FileNotFoundError:
pass
with open(f"{sys.argv[1]}.json", "w") as geodns_config: with open(f"{sys.argv[1]}.json", "w") as geodns_config:
json.dump(new_config, geodns_config, indent=2) json.dump(new_config, geodns_config, indent=2)
...@@ -107,7 +107,7 @@ ...@@ -107,7 +107,7 @@
- name: Write MDX-SAAS repo version - name: Write MDX-SAAS repo version
ansible.builtin.shell: ansible.builtin.shell:
cmd: "git rev-parse HEAD > revision" cmd: "git rev-parse HEAD > {{ geodns_config }}/revision"
chdir: "{{ mdxsaas_dir }}" chdir: "{{ mdxsaas_dir }}"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment