diff --git a/dotfiles.yml b/dotfiles.yml index c11ee24..6a07d2f 100644 --- a/dotfiles.yml +++ b/dotfiles.yml @@ -17,6 +17,7 @@ - import_tasks: tasks/shell.yml - import_tasks: tasks/fonts.yml - import_tasks: tasks/autostart.yml + - import_tasks: tasks/keepassxc.yml - import_tasks: tasks/dabapps.yml when: ansible_fqdn == "TOO-Work" diff --git a/tasks/keepassxc.yml b/tasks/keepassxc.yml new file mode 100644 index 0000000..ab09da1 --- /dev/null +++ b/tasks/keepassxc.yml @@ -0,0 +1,31 @@ +- file: + state: directory + recurse: true + path: "{{ home }}/Private" + owner: "{{ user }}" + mode: 0700 + +- set_fact: + keepassxc_config: + - {section: General, option: "SSHAgent", value: "true"} + - {section: General, option: "AutoSaveAfterEveryChange", value: "true"} + - {section: General, option: "LastOpenedDatabases", value: "{{ home }}/Private/KeePass/Password Safe.kdbx"} + - {section: General, option: "SingleInstance", value: "true"} + - {section: Http, option: "Enabled", value: "false"} + - {section: GUI, option: "ShowTrayIcon", value: "true"} + - {section: GUI, option: "MinimizeToTray", value: "true"} + - {section: GUI, option: "MinimizeOnStartup", value: "true"} + - {section: security, option: "lockdatabasescreenlock", value: "true"} + - {section: Browser, option: "Enabled", value: "true"} + - {section: Browser, option: "AlwaysAllowAccess", value: "true"} + - {section: Browser, option: "AlwaysAllowUpdate", value: "true"} + +- name: Set KeepassXC configuration + ini_file: + path: "{{ home }}/.config/keepassxc/keepassxc.ini" + mode: 0600 + owner: "{{ user }}" + section: "{{ item.section }}" + option: "{{ item.option }}" + value: "{{ item.value }}" + with_items: "{{ keepassxc_config }}" diff --git a/yamllint.yml b/yamllint.yml index 96ff9a2..aa6adf7 100644 --- a/yamllint.yml +++ b/yamllint.yml @@ -3,4 +3,4 @@ extends: default rules: document-start: "disable" line-length: - max: 100 + max: 150