diff options
-rw-r--r-- | roles/gnupg/tasks/main.yml | 2 | ||||
-rw-r--r-- | roles/gnupg/templates/systemd/dirmngr.conf.j2 | 2 | ||||
-rw-r--r-- | roles/gnupg/templates/systemd/gpg-agent-browser.conf.j2 | 2 | ||||
-rw-r--r-- | roles/gnupg/templates/systemd/gpg-agent-extra.conf.j2 | 2 | ||||
-rw-r--r-- | roles/gnupg/templates/systemd/gpg-agent-ssh.conf.j2 | 2 | ||||
-rw-r--r-- | roles/gnupg/templates/systemd/gpg-agent.conf.j2 | 2 | ||||
-rw-r--r-- | roles/init/tasks/main.yml | 1 | ||||
-rw-r--r-- | roles/init/templates/pam_environment.j2 | 2 | ||||
-rw-r--r-- | roles/tools/handlers/main.yml | 2 | ||||
-rw-r--r-- | roles/tools/tasks/main.yml | 6 | ||||
-rw-r--r-- | site.yml | 1 |
11 files changed, 13 insertions, 11 deletions
diff --git a/roles/gnupg/tasks/main.yml b/roles/gnupg/tasks/main.yml index d1289f5..ef61fed 100644 --- a/roles/gnupg/tasks/main.yml +++ b/roles/gnupg/tasks/main.yml | |||
@@ -15,11 +15,13 @@ | |||
15 | shell: 'gpgconf --list-dirs socketdir | sed -e "s@$XDG_RUNTIME_DIR/gnupg/@@"' | 15 | shell: 'gpgconf --list-dirs socketdir | sed -e "s@$XDG_RUNTIME_DIR/gnupg/@@"' |
16 | register: gnupg_runtime_dir_cmd | 16 | register: gnupg_runtime_dir_cmd |
17 | changed_when: false | 17 | changed_when: false |
18 | check_mode: no | ||
18 | - name: check existing secret key | 19 | - name: check existing secret key |
19 | shell: "gpg --list-secret-keys | grep '{{ gpg_useremail }}'" | 20 | shell: "gpg --list-secret-keys | grep '{{ gpg_useremail }}'" |
20 | changed_when: false | 21 | changed_when: false |
21 | ignore_errors: true | 22 | ignore_errors: true |
22 | register: gpgkeys | 23 | register: gpgkeys |
24 | check_mode: no | ||
23 | - name: ask for gpg password | 25 | - name: ask for gpg password |
24 | pause: | 26 | pause: |
25 | prompt: "Chose gpg password" | 27 | prompt: "Chose gpg password" |
diff --git a/roles/gnupg/templates/systemd/dirmngr.conf.j2 b/roles/gnupg/templates/systemd/dirmngr.conf.j2 index 9083ab5..529fdd7 100644 --- a/roles/gnupg/templates/systemd/dirmngr.conf.j2 +++ b/roles/gnupg/templates/systemd/dirmngr.conf.j2 | |||
@@ -1,3 +1,3 @@ | |||
1 | [Socket] | 1 | [Socket] |
2 | ListenStream= | 2 | ListenStream= |
3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.get('stdout', debug_gnupg_runtime_dir) }}/S.dirmngr | 3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.stdout }}/S.dirmngr |
diff --git a/roles/gnupg/templates/systemd/gpg-agent-browser.conf.j2 b/roles/gnupg/templates/systemd/gpg-agent-browser.conf.j2 index 61ddeb6..6dbbbc7 100644 --- a/roles/gnupg/templates/systemd/gpg-agent-browser.conf.j2 +++ b/roles/gnupg/templates/systemd/gpg-agent-browser.conf.j2 | |||
@@ -1,3 +1,3 @@ | |||
1 | [Socket] | 1 | [Socket] |
2 | ListenStream= | 2 | ListenStream= |
3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.get('stdout', debug_gnupg_runtime_dir) }}/S.gpg-agent.browser | 3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.stdout }}/S.gpg-agent.browser |
diff --git a/roles/gnupg/templates/systemd/gpg-agent-extra.conf.j2 b/roles/gnupg/templates/systemd/gpg-agent-extra.conf.j2 index f34606c..fbd5dee 100644 --- a/roles/gnupg/templates/systemd/gpg-agent-extra.conf.j2 +++ b/roles/gnupg/templates/systemd/gpg-agent-extra.conf.j2 | |||
@@ -1,3 +1,3 @@ | |||
1 | [Socket] | 1 | [Socket] |
2 | ListenStream= | 2 | ListenStream= |
3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.get('stdout', debug_gnupg_runtime_dir) }}/S.gpg-agent.extra | 3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.stdout }}/S.gpg-agent.extra |
diff --git a/roles/gnupg/templates/systemd/gpg-agent-ssh.conf.j2 b/roles/gnupg/templates/systemd/gpg-agent-ssh.conf.j2 index b7cd0c2..6f37eaa 100644 --- a/roles/gnupg/templates/systemd/gpg-agent-ssh.conf.j2 +++ b/roles/gnupg/templates/systemd/gpg-agent-ssh.conf.j2 | |||
@@ -1,3 +1,3 @@ | |||
1 | [Socket] | 1 | [Socket] |
2 | ListenStream= | 2 | ListenStream= |
3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.get('stdout', debug_gnupg_runtime_dir) }}/S.gpg-agent.ssh | 3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.stdout }}/S.gpg-agent.ssh |
diff --git a/roles/gnupg/templates/systemd/gpg-agent.conf.j2 b/roles/gnupg/templates/systemd/gpg-agent.conf.j2 index 666c22e..4f085da 100644 --- a/roles/gnupg/templates/systemd/gpg-agent.conf.j2 +++ b/roles/gnupg/templates/systemd/gpg-agent.conf.j2 | |||
@@ -1,3 +1,3 @@ | |||
1 | [Socket] | 1 | [Socket] |
2 | ListenStream= | 2 | ListenStream= |
3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.get('stdout', debug_gnupg_runtime_dir) }}/S.gpg-agent | 3 | ListenStream=%t/gnupg/{{ gnupg_runtime_dir_cmd.stdout }}/S.gpg-agent |
diff --git a/roles/init/tasks/main.yml b/roles/init/tasks/main.yml index edbd820..ce56ec4 100644 --- a/roles/init/tasks/main.yml +++ b/roles/init/tasks/main.yml | |||
@@ -3,6 +3,7 @@ | |||
3 | shell: 'GNUPGHOME=$XDG_CONFIG_HOME/gnupg gpgconf --list-dirs socketdir | sed -e "s@$XDG_RUNTIME_DIR/gnupg/@@"' | 3 | shell: 'GNUPGHOME=$XDG_CONFIG_HOME/gnupg gpgconf --list-dirs socketdir | sed -e "s@$XDG_RUNTIME_DIR/gnupg/@@"' |
4 | changed_when: false | 4 | changed_when: false |
5 | register: gnupg_runtime_dir_cmd | 5 | register: gnupg_runtime_dir_cmd |
6 | check_mode: no | ||
6 | - name: Add pam_environment | 7 | - name: Add pam_environment |
7 | register: pam_environment | 8 | register: pam_environment |
8 | template: | 9 | template: |
diff --git a/roles/init/templates/pam_environment.j2 b/roles/init/templates/pam_environment.j2 index 4327eeb..fc65a10 100644 --- a/roles/init/templates/pam_environment.j2 +++ b/roles/init/templates/pam_environment.j2 | |||
@@ -38,7 +38,7 @@ GNUPGHOME DEFAULT="${XDG_CONFIG_HOME}/gnupg" | |||
38 | 38 | ||
39 | # SSH | 39 | # SSH |
40 | SSH_AGENT_PID DEFAULT= | 40 | SSH_AGENT_PID DEFAULT= |
41 | SSH_AUTH_SOCK DEFAULT="${XDG_RUNTIME_DIR}/gnupg/{{ gnupg_runtime_dir_cmd.get('stdout', debug_gnupg_runtime_dir) }}/S.gpg-agent.ssh" | 41 | SSH_AUTH_SOCK DEFAULT="${XDG_RUNTIME_DIR}/gnupg/{{ gnupg_runtime_dir_cmd.stdout }}/S.gpg-agent.ssh" |
42 | 42 | ||
43 | # Less | 43 | # Less |
44 | LESSHISTFILE DEFAULT="${XDG_STATE_HOME}/less/history" | 44 | LESSHISTFILE DEFAULT="${XDG_STATE_HOME}/less/history" |
diff --git a/roles/tools/handlers/main.yml b/roles/tools/handlers/main.yml index a282512..a050b9b 100644 --- a/roles/tools/handlers/main.yml +++ b/roles/tools/handlers/main.yml | |||
@@ -3,3 +3,5 @@ | |||
3 | systemd: | 3 | systemd: |
4 | daemon_reload: true | 4 | daemon_reload: true |
5 | scope: user | 5 | scope: user |
6 | - name: run PlugInstall | ||
7 | shell: vim -c PlugInstall -c qa | ||
diff --git a/roles/tools/tasks/main.yml b/roles/tools/tasks/main.yml index fe5b023..70bba9d 100644 --- a/roles/tools/tasks/main.yml +++ b/roles/tools/tasks/main.yml | |||
@@ -18,13 +18,11 @@ | |||
18 | path: $XDG_STATE_HOME/psql | 18 | path: $XDG_STATE_HOME/psql |
19 | state: directory | 19 | state: directory |
20 | - name: vim config file | 20 | - name: vim config file |
21 | register: vim_result | ||
22 | copy: | 21 | copy: |
23 | src: vimrc | 22 | src: vimrc |
24 | dest: $XDG_CONFIG_HOME/vim/vimrc | 23 | dest: $XDG_CONFIG_HOME/vim/vimrc |
25 | - name: run PlugInstall | 24 | notify: |
26 | shell: vim -c PlugInstall -c qa | 25 | - run PlugInstall |
27 | when: vim_result.changed | ||
28 | - name: tmux config file | 26 | - name: tmux config file |
29 | template: | 27 | template: |
30 | src: tmux.conf.j2 | 28 | src: tmux.conf.j2 |
@@ -4,7 +4,6 @@ | |||
4 | gpg_useremail: "ismael@flony" | 4 | gpg_useremail: "ismael@flony" |
5 | gpg_realname: "Ismaël Bouya" | 5 | gpg_realname: "Ismaël Bouya" |
6 | gpg_user: "ismael" | 6 | gpg_user: "ismael" |
7 | debug_gnupg_runtime_dir: "d.sa5ao9hmm8xbjif73e5hcsfs" | ||
8 | profile: "flony" | 7 | profile: "flony" |
9 | role: | 8 | role: |
10 | flony: "fretlink" | 9 | flony: "fretlink" |