aboutsummaryrefslogtreecommitdiff
path: root/ansible
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2019-08-08 08:41:13 +0200
committerTrygve Laugstøl <trygvis@inamo.no>2019-08-08 09:03:33 +0200
commitd3197b81c89dab8f0eb412037aec42f38f0cc189 (patch)
treec59017437113a70d24c533a3cc64db80f433fdd8 /ansible
parent4547d44907029530b9d2b56f609e562daf99848c (diff)
downloadinfra-d3197b81c89dab8f0eb412037aec42f38f0cc189.tar.gz
infra-d3197b81c89dab8f0eb412037aec42f38f0cc189.tar.bz2
infra-d3197b81c89dab8f0eb412037aec42f38f0cc189.tar.xz
infra-d3197b81c89dab8f0eb412037aec42f38f0cc189.zip
borg: Adding arius.
borg-target: Adding pipelining.
Diffstat (limited to 'ansible')
-rw-r--r--ansible/borg/borg.yml6
-rw-r--r--ansible/borg/files/borg/arius/ssh-key25
-rw-r--r--ansible/borg/files/borg/arius/ssh-key.pub10
-rw-r--r--ansible/borg/group_vars/all.yml37
-rw-r--r--ansible/borg/host_vars/conflatorio/borg.yml0
-rw-r--r--ansible/roles/borg-target/tasks/borg-init.yml7
6 files changed, 66 insertions, 19 deletions
diff --git a/ansible/borg/borg.yml b/ansible/borg/borg.yml
index 61d4285..86b01eb 100644
--- a/ansible/borg/borg.yml
+++ b/ansible/borg/borg.yml
@@ -15,10 +15,15 @@
state: present
repos:
home:
+ arius:
+ state: present
+ repos:
+ home:
- hosts:
- conflatorio
- birgitte
+ - arius
roles:
- role: borg-client
tags: borg-client
@@ -27,6 +32,7 @@
- hosts:
- conflatorio
- birgitte
+ - arius
roles:
- role: borg-job
tags: borg-job
diff --git a/ansible/borg/files/borg/arius/ssh-key b/ansible/borg/files/borg/arius/ssh-key
new file mode 100644
index 0000000..f54f8d7
--- /dev/null
+++ b/ansible/borg/files/borg/arius/ssh-key
@@ -0,0 +1,25 @@
+$ANSIBLE_VAULT;1.1;AES256
+62633462653130343862363731343965303566646433613538373833393565653731666565356139
+3631383964323966303466616564623533346661333934610a356637653330623362633730666135
+62376234633262663637653930636166616261346635363366626238363130613135656633356531
+3335643936386562380a643830333132316435373265663436343366323439393833616230333631
+37623064386234336234663863393237663136663439646337363462326563353532646433303361
+62336166333730316131346266383365326532323036303330613734646438633334636266333434
+34386534376233393234396230336535353835633939343732646633376231323536326536396166
+65313961393234333131393936333236346436653566313633343263323530366464396632306463
+33626133386432373861346636363831393437333138616464623332383832326338363532346432
+35383636333031336165396164316337363937346334343731626163343162306134663562636565
+33353163613563653536643062323034376163393963626133613239646136633739366561336337
+61333330356631653264316663343630636131336163626661633665343261656361343736323436
+61663830643662353434363164383766336663373963636166393531383564663132323138623761
+33363436636466653534626564313930396161653331616661613034326134613862363030346166
+66383632346164393932633138373830613564633836666561316633616239616637336362633163
+65393633643131336235656433326336626231386362313735633232356339333734363764343537
+62663330373431643239613232656633323561313334353337373936356164306337316530383536
+37306165633835653932333935643562623564613333626336363465346266346364643339303065
+37646237663361633437326561626465376165393465316634373032336537666566346136303364
+36386531663636613438376162356539323936353138383461643533313762316230613064396534
+32386663383964326438666165653762663063666365363861393731613530393437623861393837
+62616536343265653333323830626232306533343735386661306331383862326134326439616637
+37336561303462613336333138326162653561386362313435656566373737373937343939663361
+36633061666235323531
diff --git a/ansible/borg/files/borg/arius/ssh-key.pub b/ansible/borg/files/borg/arius/ssh-key.pub
new file mode 100644
index 0000000..e3686a4
--- /dev/null
+++ b/ansible/borg/files/borg/arius/ssh-key.pub
@@ -0,0 +1,10 @@
+$ANSIBLE_VAULT;1.1;AES256
+34656264643165613566383138393864616466323135663863623231653836363135643133383232
+3430636230663335643464336630643838396566313730610a663333336534663363373461663630
+35346235366664316162356461326639613239636665643161343738306464643638313061346435
+3531343263653334390a326439666266363562326130303664643435306165363265333633396631
+30393430343832343431343135343430326639666430643831356439663239393862383332303034
+62653531363231303439386566303735383234396238346431666336316462663861373833353963
+32363966666434633562353439303533643631373534633831663166653531316230616630383631
+38373062363433386465643638643234663361386366316335616138353139343930646530633535
+6164
diff --git a/ansible/borg/group_vars/all.yml b/ansible/borg/group_vars/all.yml
index 9336f3b..e95de0e 100644
--- a/ansible/borg/group_vars/all.yml
+++ b/ansible/borg/group_vars/all.yml
@@ -1,18 +1,21 @@
$ANSIBLE_VAULT;1.1;AES256
-63386637353831373333643735383234383361643332373038363632393935653238623036623234
-3063383063323436396337356531313933626537353438360a353735666338336638343432306631
-38343963623261663933653735326264613964303138336630306431393864376465393362633963
-3264653032316333660a653932383264366633343361333934383961383461366637396138393530
-39646563386535656264636630323932303531653733343736653234663437666262656564363531
-64396138646364323039643762623835366363346264353538363431393063396666376534313832
-62356566306639333661663532363663646262353861396638323964373466656331336434656538
-30636262643335363763393139306262346339393563343737306639363962613836336633656439
-39393466373836386462303037663830383931383862663563343238643866303437346530323361
-31343139313366326634663335353235643832383064616161356565333432646130333131646337
-65356263313035396330343932363334333031623133363632623634303766383564353337333262
-32303739653738616632303664656334356666333830333931386635363437373237363138343836
-33393339303933306537356330353439623231656535663861633833323566626666336138323032
-37656665643861636363343131623838396338653034363833396538346364656235353431653339
-66643430306531383265346339623339666232363261653463333865386536393738353231376361
-30633765386237373763323837656165363431396136636662373430623937326366303834373064
-6132
+39313266306464353731363233373264623362623139633634316166373635346331343030646533
+3037313262343961653434373030623635386135386632360a376133363832656466363738393730
+33386133666536383739646536393163323037313632653232343162313065613165666435623563
+3336383935663464340a303066313338663739373937633665363033386636633239336663396566
+61626562663461626531613137316165626166343462626264626437333935643633306431636531
+34613238623732323165616531343134623334653231383665303432323365643664326331393432
+38363435376438663230343362343032333465616238393264636664666133323164623132643137
+34303736373366386237326163626363306638613737383533633762343236313435653034366137
+34393466353638393664633238636134636236373338636436633861646330313237636164623361
+63346463336131373461643633323238663065626537346565326666643732396635373935326364
+61636664356663353961643961356566373235326365623533393663666331333231643565353538
+35326664363438643837643330316264353433356362643435336466316564653538633165633633
+31316139353566626335303934616631613663633361333835396633666462373536646537346335
+62383338326661343831326237343430313061623661373561343839323463623234393736303834
+38336533383233333164363033663263633931616161386332343062343263633765343561363363
+61623437363861306136383837306161643834666430303161623237666434316361643136646333
+34323430653736636433373735646530396233616434623661663961363538613430613863373962
+34656662626264353464633530636264306238383861653963653065663331376435323333623834
+62643563313861383136313231373164633339656335343161393230346165336265623130663366
+61623661643664656563
diff --git a/ansible/borg/host_vars/conflatorio/borg.yml b/ansible/borg/host_vars/conflatorio/borg.yml
deleted file mode 100644
index e69de29..0000000
--- a/ansible/borg/host_vars/conflatorio/borg.yml
+++ /dev/null
diff --git a/ansible/roles/borg-target/tasks/borg-init.yml b/ansible/roles/borg-target/tasks/borg-init.yml
index 513b7d3..2f6efe6 100644
--- a/ansible/roles/borg-target/tasks/borg-init.yml
+++ b/ansible/roles/borg-target/tasks/borg-init.yml
@@ -6,7 +6,9 @@
success_msg: ""
- set_fact:
- ssh_key: "{{ client.value.ssh_key_path if client.value.ssh_key_path is defined else ('files/borg/' + client.key + '/ssh-key') }}"
+ ssh_key: "{{ client.value.ssh_key_path if client.value.ssh_key_path is defined else default_file_path }}"
+ vars:
+ default_file_path: "files/borg/{{ client.key }}/ssh-key"
- debug: var=ssh_key
- with_items: "{{ client.value.repos }}"
@@ -20,8 +22,8 @@
path: "{{ borg_target__home }}/repos/{{ client.key }}/{{ item }}"
- with_items: "{{ client.value.repos }}"
- name: borg init
become_user: "{{ borg_target__user }}"
+ name: borg init
command: "borg init --encryption repokey {{ path }}"
args:
creates: "{{ path }}"
@@ -29,6 +31,7 @@
BORG_PASSPHRASE: "{{ borg__passphrases[client.key][item] }}"
vars:
path: "{{ borg_target__home }}/repos/{{ client.key }}/{{ item }}"
+ ansible_ssh_pipelining: true
- local_action:
module: stat