Add profanity accounts
This commit is contained in:
parent
2a4d450d94
commit
36bc9b121a
4 changed files with 49 additions and 2 deletions
|
@ -1,4 +1,6 @@
|
||||||
---
|
---
|
||||||
|
- include_vars: vault.yml
|
||||||
|
|
||||||
- name: Install profanity (Archlinux)
|
- name: Install profanity (Archlinux)
|
||||||
become: true
|
become: true
|
||||||
pacman:
|
pacman:
|
||||||
|
@ -13,13 +15,22 @@
|
||||||
- profanity
|
- profanity
|
||||||
when: ansible_facts['distribution'] == 'Debian'
|
when: ansible_facts['distribution'] == 'Debian'
|
||||||
|
|
||||||
- name: Create needed directory
|
- name: Create needed directories
|
||||||
file:
|
file:
|
||||||
path: ~/.config/profanity
|
path: "{{ item }}"
|
||||||
state: directory
|
state: directory
|
||||||
mode: 0755
|
mode: 0755
|
||||||
|
with_items:
|
||||||
|
- ~/.config/profanity
|
||||||
|
- ~/.local/share/profanity
|
||||||
|
|
||||||
- name: Copy profanity config
|
- name: Copy profanity config
|
||||||
copy: src={{ item.src }} dest={{ item.dest }} mode=0644
|
copy: src={{ item.src }} dest={{ item.dest }} mode=0644
|
||||||
with_items:
|
with_items:
|
||||||
- {src: 'profrc', dest: '~/.config/profanity/profrc'}
|
- {src: 'profrc', dest: '~/.config/profanity/profrc'}
|
||||||
|
|
||||||
|
- name: Copy accounts
|
||||||
|
template:
|
||||||
|
src: accounts.j2
|
||||||
|
dest: ~/.local/share/profanity/accounts
|
||||||
|
mode: 0600
|
||||||
|
|
16
roles/profanity/templates/accounts.j2
Normal file
16
roles/profanity/templates/accounts.j2
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{% for account in accounts %}
|
||||||
|
[{{ account.name }}]
|
||||||
|
enabled=true
|
||||||
|
jid={{ account.jid }}
|
||||||
|
resource=profanity.{{ ansible_hostname }}
|
||||||
|
muc.nick={{ account.jid.split('@') | first }}
|
||||||
|
presence.last=online
|
||||||
|
presence.login=online
|
||||||
|
priority.online=0
|
||||||
|
priority.chat=0
|
||||||
|
priority.away=0
|
||||||
|
priority.xa=0
|
||||||
|
priority.dnd=0
|
||||||
|
eval_password={{ account.eval_password }}
|
||||||
|
|
||||||
|
{% endfor %}
|
2
roles/profanity/vars/main.yml
Normal file
2
roles/profanity/vars/main.yml
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
---
|
||||||
|
accounts: "{{ vault_accounts }}"
|
18
roles/profanity/vars/vault.yml
Normal file
18
roles/profanity/vars/vault.yml
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
$ANSIBLE_VAULT;1.1;AES256
|
||||||
|
35326533373839613637386131386661343261383261376533333233636535376463666635366462
|
||||||
|
3033613730313731633738613133316465646161646630650a613635646438656362333630353463
|
||||||
|
35643239346638376330343961653132346232653665326636306334303036396234326537623935
|
||||||
|
6436393732373236350a383635643665626663636335323761346561383231393564316262643235
|
||||||
|
61343861313735623138303637633037313162343666613136343161613235613138323162313064
|
||||||
|
37653030316337623162306233643336336139376261633839333135623964616332303061633566
|
||||||
|
34386363316464613165643563613862386435613965626331613939646134623537333861303232
|
||||||
|
32303039353633336235303531346433613832613937376564363234386163363732643434623935
|
||||||
|
65336266653264363965386464363738616662643662653066666237636232343930333334333061
|
||||||
|
32393163313738333936326637383536653836313539316230333765626465353234376534353232
|
||||||
|
63663530343036316131636538333633663730666165623862366437316664643532386534333861
|
||||||
|
39613231396262396130653438353431646639386364636538383963323565386437613962336461
|
||||||
|
31383166303138383437326561653130346635373763633364323133643830306638316163393730
|
||||||
|
38353135326637663661653931316666376335323034396661666138633738376432663137363632
|
||||||
|
64623266316532333738303138653332366634383662323566636234633133323239626335643264
|
||||||
|
30326131353230333261373837313961353664316634643236366231626338623137343234333564
|
||||||
|
3739
|
Loading…
Add table
Reference in a new issue