feat: add password for twirre user

This commit is contained in:
Twirre Meulenbelt
2026-04-22 18:48:28 +02:00
parent d8f4307969
commit 6939f40a9f
4 changed files with 9 additions and 1 deletions

View File

@@ -29,6 +29,7 @@ ssh_admin_users:
- name: twirre - name: twirre
shell: /bin/bash shell: /bin/bash
groups: "{{ ssh_admin_groups }}" groups: "{{ ssh_admin_groups }}"
password: "{{ vault_twirre_password_hash }}"
authorized_keys: authorized_keys:
- ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKSmroAJ4SDziZtwg+PCNITuhPim8oseq/sNwW0jTLJc twirre@gwen - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKSmroAJ4SDziZtwg+PCNITuhPim8oseq/sNwW0jTLJc twirre@gwen
- ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIfapo7P0vmwkTdD9kkHaalk9U+JYIZuCp/hFTnPRqTp twirre@ben - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIIfapo7P0vmwkTdD9kkHaalk9U+JYIZuCp/hFTnPRqTp twirre@ben

View File

@@ -15,6 +15,10 @@ vault_gitea_secret_key: REPLACE_ME
vault_gitea_internal_token: REPLACE_ME vault_gitea_internal_token: REPLACE_ME
vault_gitea_lfs_jwt_secret: REPLACE_ME vault_gitea_lfs_jwt_secret: REPLACE_ME
# Store a hash here, not the plaintext password.
# Generate a SHA-512 password hash with: `openssl passwd -6`
vault_twirre_password_hash: REPLACE_ME
vault_mailserver_accounts: | vault_mailserver_accounts: |
# One account per line: email|{SCHEME}hashed-password # One account per line: email|{SCHEME}hashed-password
# Example: # Example:

View File

@@ -1,4 +1,5 @@
{% set app_vault_env = vars['vault_' + (bun_app.name | replace('-', '_')) + '_env'] | default({}) %} {% set app_vault_env_var = 'vault_' + (bun_app.name | replace('-', '_')) + '_env' %}
{% set app_vault_env = lookup('vars', app_vault_env_var, default={}) %}
{% set app_non_vault_env_keys = bun_app.non_vault_env_keys | default([]) %} {% set app_non_vault_env_keys = bun_app.non_vault_env_keys | default([]) %}
{% set app_filtered_vault_env = app_vault_env | dict2items | rejectattr('key', 'in', app_non_vault_env_keys) | items2dict %} {% set app_filtered_vault_env = app_vault_env | dict2items | rejectattr('key', 'in', app_non_vault_env_keys) | items2dict %}
{% for key, value in (bun_app.env | combine(app_filtered_vault_env)) | dictsort %} {% for key, value in (bun_app.env | combine(app_filtered_vault_env)) | dictsort %}

View File

@@ -16,6 +16,8 @@
name: "{{ item.name }}" name: "{{ item.name }}"
shell: "{{ item.shell | default('/bin/bash') }}" shell: "{{ item.shell | default('/bin/bash') }}"
groups: "{{ item.groups | default([]) }}" groups: "{{ item.groups | default([]) }}"
password: "{{ item.password | default(omit) }}"
update_password: always
append: true append: true
create_home: true create_home: true
state: present state: present