feat: add new parameter ansible.file_with_secrets
This commit is contained in:
parent
03af28c835
commit
6d2bc9592b
6 changed files with 63 additions and 18 deletions
|
@ -5,8 +5,8 @@
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: \n"
|
"Project-Id-Version: \n"
|
||||||
"POT-Creation-Date: 2024-11-27 16:19+0100\n"
|
"POT-Creation-Date: 2025-02-10 09:15+0100\n"
|
||||||
"PO-Revision-Date: 2024-11-27 16:21+0100\n"
|
"PO-Revision-Date: 2025-02-10 09:15+0100\n"
|
||||||
"Last-Translator: \n"
|
"Last-Translator: \n"
|
||||||
"Language-Team: \n"
|
"Language-Team: \n"
|
||||||
"Language: fr\n"
|
"Language: fr\n"
|
||||||
|
@ -16,6 +16,24 @@ msgstr ""
|
||||||
"Generated-By: pygettext.py 1.5\n"
|
"Generated-By: pygettext.py 1.5\n"
|
||||||
"X-Generator: Poedit 3.5\n"
|
"X-Generator: Poedit 3.5\n"
|
||||||
|
|
||||||
#: src/rougail/user_data_ansible/__init__.py:46
|
#: src/rougail/user_data_ansible/__init__.py:47
|
||||||
msgid "ansible is not set in step.user_data"
|
msgid "ansible is not set in step.user_data"
|
||||||
msgstr "ansible n'est pas définit dans step.user_data"
|
msgstr "ansible n'est pas définit dans step.user_data"
|
||||||
|
|
||||||
|
#: src/rougail/user_data_ansible/config.py:30
|
||||||
|
msgid "Configuration of user data Ansible"
|
||||||
|
msgstr "Configuration des données utilisateurs Ansible"
|
||||||
|
|
||||||
|
#: src/rougail/user_data_ansible/config.py:39
|
||||||
|
msgid "Ansible filename inventory"
|
||||||
|
msgstr "Nom du fichier d'inventaire Ansible"
|
||||||
|
|
||||||
|
#: src/rougail/user_data_ansible/config.py:55
|
||||||
|
msgid "Secret to decrypt file"
|
||||||
|
msgstr "Secret pour déchiffrer le fichier"
|
||||||
|
|
||||||
|
#: src/rougail/user_data_ansible/config.py:65
|
||||||
|
#, fuzzy
|
||||||
|
#| msgid "Ansible file that may contain passwords"
|
||||||
|
msgid "Ansible file that may contain secrets"
|
||||||
|
msgstr "Fichier Ansible qui peuvent contenir des secrets"
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: PACKAGE VERSION\n"
|
"Project-Id-Version: PACKAGE VERSION\n"
|
||||||
"POT-Creation-Date: 2024-11-27 16:21+0100\n"
|
"POT-Creation-Date: 2025-02-10 09:16+0100\n"
|
||||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||||
|
@ -15,7 +15,23 @@ msgstr ""
|
||||||
"Generated-By: pygettext.py 1.5\n"
|
"Generated-By: pygettext.py 1.5\n"
|
||||||
|
|
||||||
|
|
||||||
#: src/rougail/user_data_ansible/__init__.py:46
|
#: src/rougail/user_data_ansible/__init__.py:47
|
||||||
msgid "ansible is not set in step.user_data"
|
msgid "ansible is not set in step.user_data"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
#: src/rougail/user_data_ansible/config.py:30
|
||||||
|
msgid "Configuration of user data Ansible"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: src/rougail/user_data_ansible/config.py:39
|
||||||
|
msgid "Ansible filename inventory"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: src/rougail/user_data_ansible/config.py:55
|
||||||
|
msgid "Secret to decrypt file"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: src/rougail/user_data_ansible/config.py:65
|
||||||
|
msgid "Ansible file that may contain secrets"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
"""
|
"""
|
||||||
Silique (https://www.silique.fr)
|
Silique (https://www.silique.fr)
|
||||||
Copyright (C) 2024
|
Copyright (C) 2024-2025
|
||||||
|
|
||||||
This program is free software: you can redistribute it and/or modify it
|
This program is free software: you can redistribute it and/or modify it
|
||||||
under the terms of the GNU Lesser General Public License as published by the
|
under the terms of the GNU Lesser General Public License as published by the
|
||||||
|
@ -48,6 +48,7 @@ class RougailUserDataAnsible(RougailUserDataYaml):
|
||||||
self.rougailconfig = rougailconfig
|
self.rougailconfig = rougailconfig
|
||||||
self.filenames = self.rougailconfig["ansible.filename"]
|
self.filenames = self.rougailconfig["ansible.filename"]
|
||||||
self.secret = self.rougailconfig["ansible.secret"]
|
self.secret = self.rougailconfig["ansible.secret"]
|
||||||
|
self.file_with_secrets = self.rougailconfig["ansible.file_with_secrets"]
|
||||||
self.config = config
|
self.config = config
|
||||||
self.errors = []
|
self.errors = []
|
||||||
self.warnings = []
|
self.warnings = []
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
"""
|
"""
|
||||||
Silique (https://www.silique.fr)
|
Silique (https://www.silique.fr)
|
||||||
Copyright (C) 2024
|
Copyright (C) 2024-2025
|
||||||
|
|
||||||
This program is free software: you can redistribute it and/or modify it
|
This program is free software: you can redistribute it and/or modify it
|
||||||
under the terms of the GNU Lesser General Public License as published by the
|
under the terms of the GNU Lesser General Public License as published by the
|
||||||
|
@ -15,6 +15,7 @@ details.
|
||||||
You should have received a copy of the GNU Lesser General Public License
|
You should have received a copy of the GNU Lesser General Public License
|
||||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
"""
|
"""
|
||||||
|
from .i18n import _
|
||||||
|
|
||||||
|
|
||||||
def get_rougail_config(
|
def get_rougail_config(
|
||||||
|
@ -24,18 +25,18 @@ def get_rougail_config(
|
||||||
"""get rougail config for ansible"""
|
"""get rougail config for ansible"""
|
||||||
# redefine ansible family if already exists (for output)
|
# redefine ansible family if already exists (for output)
|
||||||
# or create a new only only for user data
|
# or create a new only only for user data
|
||||||
options = """
|
options = f"""
|
||||||
ansible:
|
ansible:
|
||||||
description: Configuration of user data Ansible
|
description: {_("Configuration of user data Ansible")}
|
||||||
disabled:
|
disabled:
|
||||||
type: jinja
|
type: jinja
|
||||||
jinja: |
|
jinja: |
|
||||||
{% if 'ansible' not in step.user_data %}
|
{{% if 'ansible' not in step.user_data %}}
|
||||||
disabled
|
disabled
|
||||||
{% endif %}
|
{{% endif %}}
|
||||||
|
|
||||||
filename:
|
filename:
|
||||||
description: Ansible filename inventory
|
description: {_("Ansible filename inventory")}
|
||||||
type: unix_filename
|
type: unix_filename
|
||||||
multi: true
|
multi: true
|
||||||
params:
|
params:
|
||||||
|
@ -46,19 +47,28 @@ ansible:
|
||||||
disabled:
|
disabled:
|
||||||
type: jinja
|
type: jinja
|
||||||
jinja: |
|
jinja: |
|
||||||
{% if 'ansible' not in step.user_data %}
|
{{% if 'ansible' not in step.user_data %}}
|
||||||
disabled
|
disabled
|
||||||
{% endif %}
|
{{% endif %}}
|
||||||
|
|
||||||
secret:
|
secret:
|
||||||
description: Secret to decrypt file
|
description: {_("Secret to decrypt file")}
|
||||||
type: secret
|
type: secret
|
||||||
disabled:
|
disabled:
|
||||||
type: jinja
|
type: jinja
|
||||||
jinja: |
|
jinja: |
|
||||||
{% if 'ansible' not in step.user_data %}
|
{{% if 'ansible' not in step.user_data %}}
|
||||||
disabled
|
disabled
|
||||||
{% endif %}
|
{{% endif %}}
|
||||||
|
|
||||||
|
file_with_secrets:
|
||||||
|
description: {_("Ansible file that may contain secrets")}
|
||||||
|
default: all
|
||||||
|
choices:
|
||||||
|
- all
|
||||||
|
- first
|
||||||
|
- last
|
||||||
|
- none
|
||||||
"""
|
"""
|
||||||
return {
|
return {
|
||||||
"name": "ansible",
|
"name": "ansible",
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
"""Internationalisation utilities
|
"""Internationalisation utilities
|
||||||
Silique (https://www.silique.fr)
|
Silique (https://www.silique.fr)
|
||||||
Copyright (C) 2024
|
Copyright (C) 2024-2025
|
||||||
|
|
||||||
This program is free software: you can redistribute it and/or modify it
|
This program is free software: you can redistribute it and/or modify it
|
||||||
under the terms of the GNU Lesser General Public License as published by the
|
under the terms of the GNU Lesser General Public License as published by the
|
||||||
|
|
Binary file not shown.
Loading…
Reference in a new issue