From 3f9fd2770c07817d0a57e9ea260a212ea9aef7b7 Mon Sep 17 00:00:00 2001 From: Vincent Lafeychine Date: Sun, 5 Nov 2023 09:50:27 +0100 Subject: [PATCH] chore(osm2pgsql): Ensure account using meta, adding variable configuration --- .config/ansible-lint-ignore.txt | 1 - osm2pgsql.yml | 7 +------ roles/osm2pgsql/defaults/main.yml | 3 +++ roles/osm2pgsql/meta/main.yml | 8 ++++++++ 4 files changed, 12 insertions(+), 7 deletions(-) create mode 100644 roles/osm2pgsql/defaults/main.yml create mode 100644 roles/osm2pgsql/meta/main.yml diff --git a/.config/ansible-lint-ignore.txt b/.config/ansible-lint-ignore.txt index 6e0bb30..51119d6 100644 --- a/.config/ansible-lint-ignore.txt +++ b/.config/ansible-lint-ignore.txt @@ -15,7 +15,6 @@ live.yml name[casing] munin-server.yml name[casing] nextcloud.yml name[casing] ocitysmap.yml name[casing] -osm2pgsql.yml name[casing] osmbin.yml name[casing] osmose-backend.yml name[casing] osmose-frontend.yml name[casing] diff --git a/osm2pgsql.yml b/osm2pgsql.yml index ad31b8c..ff464fd 100644 --- a/osm2pgsql.yml +++ b/osm2pgsql.yml @@ -1,11 +1,6 @@ -- name: osm2pgsql configuration +- name: Configure osm2pgsql hosts: osm2pgsql gather_facts: no become: yes roles: - - accounts - osm2pgsql - vars: - accounts__users: - osm2pgsql: - service: true diff --git a/roles/osm2pgsql/defaults/main.yml b/roles/osm2pgsql/defaults/main.yml new file mode 100644 index 0000000..362fbab --- /dev/null +++ b/roles/osm2pgsql/defaults/main.yml @@ -0,0 +1,3 @@ +--- +osm2pgsql__user: osm2pgsql +... diff --git a/roles/osm2pgsql/meta/main.yml b/roles/osm2pgsql/meta/main.yml new file mode 100644 index 0000000..5bd77c1 --- /dev/null +++ b/roles/osm2pgsql/meta/main.yml @@ -0,0 +1,8 @@ +--- +dependencies: + - role: accounts + vars: + accounts__users: + "{{ osm2pgsql__user }}": + service: true +...