diff options
Diffstat (limited to 'skillz')
29 files changed, 1025 insertions, 0 deletions
diff --git a/skillz/cloud-install.yml b/skillz/cloud-install.yml new file mode 100644 index 00000000..72db81d9 --- /dev/null +++ b/skillz/cloud-install.yml @@ -0,0 +1,10 @@ +--- +- name: cook variables for host + hosts: "{{ install_hostname }}" + gather_facts: no + tasks: + - set_fact: + install: "{{ install | default({}) }}" + network: "{{ network | default({}) }}" + +- import_playbook: ../common/cloud-install.yml diff --git a/skillz/common.yml b/skillz/common.yml new file mode 100644 index 00000000..af4b4fda --- /dev/null +++ b/skillz/common.yml @@ -0,0 +1,10 @@ +--- +- name: Basic Setup + hosts: "{{ install_hostname }}" + roles: + - role: apt-repo/base + when: ansible_pkg_mgr == "apt" + - role: core/base + - role: core/sshd/base + - role: core/zsh + - role: core/ntp diff --git a/skillz/generic.yml b/skillz/generic.yml new file mode 100644 index 00000000..bc8866c5 --- /dev/null +++ b/skillz/generic.yml @@ -0,0 +1,5 @@ +--- +- name: "Apply role {{ myrole }} to hosts: {{ myhosts }}" + hosts: "{{ myhosts }}" + roles: + - role: "{{ myrole }}" diff --git a/skillz/group_vars/all.yml b/skillz/group_vars/all.yml new file mode 100644 index 00000000..c1689af2 --- /dev/null +++ b/skillz/group_vars/all.yml @@ -0,0 +1,26 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +34303062356563613439616633656336306230363866343163613162653231623035393632373163 +6661303664363964666162363563393366356637643866330a313262633532393432336664363630 +61363631313631386331326331396663326564353137343433323631313737666164343836366165 +6136656337306365380a376163393163336437653365366266653464383036626565633039323631 +36356433306432653637316630323338353339373430356361613861663465386236383831396235 +62343637336665653665376337623435303033303961656430313164363364343233346630626565 +35303032323239373863306465393436383864636233316664663061346232383563366166343536 +65613730363563663831633063663933633935303937373263376264303339643333363037383232 +31363039393734323064366237326565333761386330316166666434643732626466313733326434 +61613939643165336233333664343130636337373838653734363639356532326633353064643731 +62366330656333653164303661373666363638323832623364336230326263653030613464396634 +64356339656462386432626464356665323736383464386362393832356530303236643733373562 +39316561393338386436353536653062386335383066343461663837363362646365393966656266 +30363238636431366330313032346437626664326336663230663338303061333233316334343535 +37613037376134656435343166356162616434343335663234326439336131356264666639643335 +38343030346635656638363439383030373362356236613466373938613762633462303362313238 +34323831336666633437316237333766386464383037303235303939346533626433333664663434 +62663762396366633663326633363433656565653633396561383338343061643234663230393563 +66353233613066353732326361383337386466643064343561333836363861373130623963336139 +62356131396237323232333936393232373939656465663032333564333564396331623535623966 +38306136313234326237633964346666313165373630356362333038636365326161303164646232 +37393863353262343631613631323234343664366531376439643137326131323738303963663534 +63366638653632363965383834633432343136653031313864396532343036346635346663306539 +31303064663963323934323931623164303564616632663631346437316462323138376139333164 +6635 diff --git a/skillz/host_vars/sk-2019.yml b/skillz/host_vars/sk-2019.yml new file mode 100644 index 00000000..908c08a7 --- /dev/null +++ b/skillz/host_vars/sk-2019.yml @@ -0,0 +1,21 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +35326231663932373064373761356464353663663232666435613835336631366237343964313433 +3765646361386137366363656635396336363334326235330a376165353932363763366562313638 +32646366363530613565396232373664346138373465393964616336333433313966393938336438 +6434626536363937630a663165643238616164353138666131643739323361616262663461326439 +64646365356134323637376338353934303031653863353765313062653737306664643330313832 +32663461623263373164383632363233336364393138383764353531363331616435393764313034 +30623438313239373462656131323935663832303937396461303035373538383333353730336633 +34633234323736306263613030643339636435356432333437376266626461396634313534646462 +34666630653636373333306262323663333366363436353662346563666264663639353530326466 +64303436646636333233663635623065323462333962346335323534663033636464343035363034 +62393665353730356338393734613630646334316164376139336237373839643564393562306333 +65383434373666303930326566323937363661396262616437646530636130653032656630353432 +39343662336661363163646531383430376338363362386566343464363062383730643932616566 +35346439346138666233653933653866376231666466613439383230396635396561393330313062 +64656365313366396138356436616461396331393137613936333438376231373361623637393432 +32333333663263623965383534643632663561626566636236643436616630623535636237633932 +37663834366165306262393131356262353131666230623033633231316436643566616337633835 +61613261313164356365666430353763323761663533656134653030633032336166663734373539 +39393933643261313463383739633530336539323661376239383235623830623339633963323635 +36353930666438613330 diff --git a/skillz/host_vars/sk-2019vm.yml b/skillz/host_vars/sk-2019vm.yml new file mode 100644 index 00000000..d81283be --- /dev/null +++ b/skillz/host_vars/sk-2019vm.yml @@ -0,0 +1,21 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +36643464643335623666313430333664646430326235383430346639616631316463653435653066 +3666353361383635613138643966356663343266303532660a366139616338363834363134663834 +39343432313233666164366363613936346464333330316332656337626361636133626335306438 +6163646330613732370a393338623232336631323538393136653930666665313461333435393838 +32313866313836646662656532326366333430636333396365663461653537333633663163653661 +62303035653165663531653961623237386135393139363464363437663064653131323737623234 +38626232653138633863646366623536353561306166303361653835326535636439643165333865 +61386363353833326433656236653437336463396532306536336261333934313538623735663338 +34383264353962373361643936626433646663386465646462653661316461653837613564346563 +35646438343864626466323239363630336534666635666331613630396438336561356236323330 +61623139363132633163366666333036336264303737303165616565343261353164323138336262 +30653030393436376234343031616138346266623638306633326665626137336661333638646337 +33306565386430343230303166303238653562636634653364323461666339343763393065386432 +36333638303563333336353561613434353033613138626236303138343637663164646632373262 +35306462363933366439326264373034633963313334633232393336336332393030323433353162 +38386632303165343631636165353264306262363365613231643338303938653835383230376262 +61366233643831393064353430316636356362346537346137383839356337353730353964323038 +39636631616433653331643232623665346466323365633631396363643234653963616233613332 +30396132336338396661393736363630313965626161356530393338396562363665363636656430 +30656437656532396233 diff --git a/skillz/host_vars/sk-2024.yml b/skillz/host_vars/sk-2024.yml new file mode 100644 index 00000000..70a66843 --- /dev/null +++ b/skillz/host_vars/sk-2024.yml @@ -0,0 +1,22 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +33613131383766346466323766306266393038393964613864653561333032663262366237313231 +6433303530396233373633656433616136373537336263390a346234376363376136323633633538 +36626337313837303565346535303031316664663733343063613039386566633362353034313665 +3036636133623438340a373935393438353537383664343865393462656162613339376132356632 +34303736343539386532663761313666356136353230633138323934363431363833336237633236 +65316263636530633662356561623866633662323434393961336331633339303839303838626239 +36323262666163346536333537623362653462313335313436393039336235313263386432326133 +31643961353362613230663832356237383338363464346230666230666333663961633065333963 +66303265313332333365313164333330656163643937383138393338346663633361623364336433 +63356231376435366561653236643866393161653830643166313666376463373565656336653466 +39363063316663356632343037356438383061363964373836626334643362323932333736376666 +62383765393732643734633031363365316335366235333433663762663762396334636333303630 +62386133393266626561336463323963616661333563303331383237366337363631393566613866 +62363962363239626461393636393733623833303734343137643036636635333937383665353662 +30633965323236326232393837366566633865633338313638373138386332303464383631623235 +32343236646364313234316135646431396437653265643562663536383961646132636635393939 +35303066626233646664306139643964343863353635323032343664633639633831653931616262 +62613961316132623638393632336566653133666230613962303264663835303165343537393236 +30333362616431636666636337326366396635346161613965313839306230643165633765323339 +34393831396665623634653237353932373062376135316133366464393837366630633139633533 +36316237323738653837646565323563363939343738383933306565616437336261 diff --git a/skillz/host_vars/sk-cloudio.yml b/skillz/host_vars/sk-cloudio.yml new file mode 100644 index 00000000..9eb8ad1e --- /dev/null +++ b/skillz/host_vars/sk-cloudio.yml @@ -0,0 +1,246 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +66353130383062316462386138393335326535393536316339393131633237376230323634346639 +3266363564396662313666663961653938663061616262380a363961346366333566366438336636 +32326631663164383838383330363839313631346139303039663835353963366330356366616435 +3735643034343738640a386433623163613964666561373436316363616238356233313730323038 +65393034326539636232343734383331666332346561393633616535666334313736373536663031 +30393733623535303639396462623236303062373937646235636138346339313964373634646632 +33356464316534366638666634636234313238343037376430643237336337323565666535363666 +33306537613534313733616333633461366632616562366639353231376637313365303961636339 +38336238386266376361363339623036386136326363343766623962623330643732386432623166 +36643536623230663338623064633837393866386361643439313965643432333034306533626664 +38633632323432303966343266313666643563323733313364306633346135643234623830613465 +37373234376261666364616564653339356234336437383337366435626130636265653634653734 +65663738646137393734343066303139323033383864353134363666333131613230636462613638 +66636564333063643930353961623033353561386662613862356661383065636435343736303262 +38373434383338353562623032326462373735376632303464663835393763316465343238626231 +30623734366161303838626539383933376364356232626239613732613933376264356665613537 +65623331313537306230356632343133356131373331663030656332636430396664633661363039 +64383736333862613565346135666164333732313733663934376435303535386538353465633163 +66353833376462623230623535666339663431393232353964373038376430643139333134306336 +65643635313263613632386331626433363638303432623032633963313165313031626463326638 +36666532623533363635353161326331333462343633623965646433313965373537653463343061 +34336237616461663436306165353837643633346362323762313734313739643363326239353437 +38343038373531333666663430386662663365646464306530333035613038383630386332383030 +63323133353435336338346564343435636264643961393261376130383932326330663030346538 +33376632306338626231666338376139356639323734636664343666616138353131616262343436 +61373866366139333437336336343362636331356161363165366561316462613434346461643939 +35326366313864346235316362663961313330336263643733333539633630363666303835643332 +30313833616439373165333862346134613163326138323164353937336639376136393338366530 +36383637653462373064653566643733396136616135373163656431306436343235366232666564 +66646231376431386636323530663930313531353633353232653833323963646333346530643266 +32626564623761323065666236316664396663303738353935613333646431333233303062633330 +66373735316337663239346338633765363466333236323836663163616631343730623265323261 +30666634376265383736636164363236636638376234653761313133666365346466306261353334 +34306631643333666262336233306365386365623264663664613136393963376466323438393931 +61346535333164303030623261303134653939333338663634636661373063393165616530303638 +34303832386464643435386338313339316665313662336233356664653439353031363663333532 +36383036633336343332326530303831366631396236396666663032396166656538666566623138 +34383661373733326664353730306338666362363164623736323661343163653866343636633462 +61643032613563663537656135353037666430393631623232363866346162396361633736383031 +66353034623664643366623262663764313364356333313165306664613732666562366566623663 +66356464323364643733363965306132663366376462346261366365333966333334383630633532 +32373235393439623737623336313035633137646435643863363566373035663033353937623433 +66343636656537666530663138373837306533366464643264343937313963633434316564303731 +30363535313365656136326563306136656635616131396565313962646162353638346231616332 +63373263353435316236633934316232656631646136343764373562373730613735663262633162 +36633139316465323733383362623734383639393462366262313335313862656161313234643838 +35663030353837323863303935663166643732383634383666323631306335353164323464626635 +36626661383462303536626438346139376338313863643836336130303037623065376638613631 +32623034383762386535386331376464346139663462333033656235336537656566373861346366 +39303464393639616637316665663261663236663461363830366163396333653664353731666331 +63336464343866393962303338623962316330663333653334356130333166666161373339366237 +61316465626430343264323037633439313135356334373732343632303164313036336362326432 +39613639656266303762363632666461366531653437393537303530613861343536663230323238 +39613736356566613733303636613966393437363265316263376637306663313337343366393366 +65623861643763343866343063313731396466316339356565336566316432326535363239663039 +38653961393935343962346235376536323463663639643235663130616235376366356366313535 +61346438313361333165386631623933386439323035303765616535343735383030333832373432 +30373466323538356232663637346338653435306261373332393935613366626565653766656533 +66616638653263343766363962633337313930323262646230396563633061363230336133646633 +65663138626239643631663338313435313431663365303238626433633039633762353761316265 +35353463616566653534363535646439343161393639363532366265303565343761653062373038 +31313636363331396237663132366632626663313038356163323065383939346361313066363764 +34363063626263626433353439646237316631363933386637623130666336343164633437326337 +35373633363538333834316566376634393434333336663333653265363234366430643165633830 +66396162313130316539316134333538653935306635353137383065646465623337346366373539 +61376237393335346538643463366134383333396137653262623839343961663036663962666262 +33616532646638346261666238623166623133303438643462383430393032346334663161366333 +39323964353037666165653935616431306263616634353239633730346164376333386430353334 +37373233663565353337316238343766313766633737356562663038363234636431353665306535 +30373035653330303437306230646337343966306161623666313532653862646331646633656563 +37663539613730646235613031326534616531346661663765393730393935316365366164323164 +32383363313862323931376234323330353637373930353432653536636564663738613130613934 +38303235663939663630316566333338336539393933323766613161623162653532346236353936 +32383864306363353936663265653565396438366534396633663139306264666562323237653837 +38373062316232653866623435353463313265323139343334346337313130636165356665363030 +66346630303431633066333139626661616631386232633765613166303231626231653438363331 +38306134663063613766363037626338393464396237656337343362366261396166343538393162 +35373730356532656166396163663830623137623531633066373832303130653131333639383062 +34623738326562643264636166343865363333343633356136353633333063636239663136366333 +66366635333966636632386330643265393865386534333865313464663531633231663839616534 +33326565363134633662363166363666643538643637383765613730346331626537303235366561 +33666132633836323133373131653363326438346664623039303762393139666331626161343437 +39303136383734343664646638326432613965616165323734356632323634303337663430373439 +36346231333863636338383964633230353832373434623234333130383137386666626339313064 +35653862313663633061396530303665303963396438346337386262616164663334613632316565 +38333763643936336336656361633165353733333936643835633337626434303631326162643739 +35363732666639323836383662313431376537346162333361656232636165626636316366623065 +63333638656130666632633837626266363237313935346164383331333532653134386330383435 +30613137306466643130633134353464613131323831613765656533396438643061383165373131 +61663262663661316161653236353831316337386336313432646366336635323936623738636139 +63323364366330306631343836363431363630623963653237386232366464633733663561323764 +64343463313432303434383432316639663262383538316633393733623839663639373636336566 +37656138323431373537303738646336323261316532343465616661653735636532396639633936 +64616537333833623634656436656361636465653039653931653239623765626563316363316535 +64323830666561316639333330643237313136626363333661386565653164353537396565323431 +35363665383061363434623464383737303361633039623738393966666434353862353234326336 +66666532646163303337626236653263386230333864323963376238353461313966643762653063 +30373662613434346163313933386664633933616134613134356230353561633966353233396162 +62623232663165623562363661613137353038646162653135326663386132646231303038303338 +35613534333837323465623361363061336163323361616538643566376438653933653965636536 +37303961353165623361346535383832393632663166393766396230643939313530623765356334 +36663237393634323037623431643361623830373536663532313736633035623062346363623766 +34613861323864663662383231366335386362323865623137613032636235373163626537393661 +64663638343662623364303035343432623335323533663864616436356233383732383662333066 +39663765623334623662353133373835326133333062323963376431663134353761613464643061 +35623737643336653962343431306431303132343935303932613764313838303230653664643562 +35666436616663633939323932373539396161306664636637623663313334656165393963363137 +38643461316430383732666536633335663233336639653239653630333762353065633432666661 +63363931623335613466393461333431613764636438613733383062353763343530343631663037 +37313861333962313831646337376134356133323233396365613030643430303364326232636462 +61386564663161313964323234313034343666303130316662353638666661373439383335616564 +35323863643965656566313465613166326362616539643030306165336439393930373465663530 +30316265346165333030616433326332643362633135393065623239613736353465633562663864 +36663932356430303163336136353964393366316236336432313738653236353261623732633334 +31643938656264303330393961376236626563643630393730373334643064343237386532643138 +34333864326335393336363963393532623036326532366138643432636462643238376635363062 +63336263303536376636303937363937373633356466346438306138326232613935373433346231 +33313864353830663264343838396365326437613330363365663031353566643661366631353134 +34646132613137613266303365366236626131363033346330616438323861316438316430303962 +38653165343638316363623361353435383166333162613139636331373138333232623830376334 +39636166373138663265393037663062363433326337376134376265373630396566333038343265 +36333464383566303466303938623932313033336131316430383937313164343663646335353731 +33653262353736373338306439326333303365343937393766306234393034643730613263393132 +62666163663031323433623630666161656536626232373433633733343936643265636536656638 +30353734386463313534623531383537353338306431353135393130306564643036386334333335 +65323238356239633731353865626236646334623038333365373664653431306335623133313731 +64646237333566613638333039376533663763393064633237323566326166363764633935656262 +61363566363736616437306230333732613335313463643236613139326538313762396137626135 +36653161353033666265646665353531653035386336666235626162646561383138653165303132 +38323162313266643165373837326662346266653030393331333237323230366564643138303939 +64353730303938356430353066343630636234326636623135383131393663323033613130633034 +62623734653662393831376664633564643736663839356365326134636533326364356563393030 +66633164663930336530323461646165393038363731373437613535313930316561333064323337 +64353033373265323334393530316234363330373766333730646439363739613365653337333033 +65346466323965376462646364366133666664353766396165363466646235313035613333313565 +65633032306435613030363461303037616639353463313565646432353565353239313634313535 +63353739393361663735623839326562656336363464373934633562396534633132623730313562 +37343361373366336665323232353234613431336437393266643663666137306662653061376435 +35623062333938653733313134383735356463646332333437653766366164663164326465303265 +61383730623663306566376631353531613763626135643866346139306162313964383839653333 +38646635663034643136646635393131373737646133306665346338343162653430353332323930 +30613966343162303334383437303464353232303961316363633839633130653432346132633337 +33373263303930383565323136306131316564396338343630346535326533626661366565356166 +30643937666466613633346439393336633665303831623337663439326230653637613939616438 +33373634303833636665643866333031316435336465326632376431306636366330363935636236 +65346566363438633664393937373330666262323739336539383337613662663661363163633133 +61663063376361316637653530326364313733383662376461326664373330363630336439313632 +64616266343038656262663730393636316535666363303730343631323764303930633339616563 +33303332313431356339393363366330323430306137353062353235653534303836393636306466 +30623231626234623435613366363437326165356431636464663631306237323533383565383733 +36336138323032303364346134613565626137633662353536363937323931393363633636316133 +64356339316534653965303530656266633761653764393633643562623132663230393931313539 +63343865636631336163623933393737373339303737313466663764656130316263303063616664 +36613933376361633134366136346239333738393063373033663831303562396237306531356136 +65393734663638326138663331303163383764363639633033393330386638646430623030653331 +33393036393462653232386334656635616437316237653663646438366464386239373864663462 +64646466336665316135336665643137366333316534316661336530623665376132353533633532 +35623636396264323034316339363336306538306465663561326566396434636434616338623930 +35393861393365653136323764353433386662323139393231343262346432303261313661383162 +30663966613661316432373361653034613839613761386266396134373261613161623565666537 +38326564663338393261653435323238666565363061306137636266393431613162373561653930 +30636137323362613662353930323333376635323134316430636135623061663762313639306433 +38313466656439643965376163346562303737333663353562373165303339393530303935323639 +36386333376361383365346333366463623032653231346130323032356632353331663964313035 +38666235633061616536376266613132386432376561316132666234333930616462386237356238 +33386561383331313738653538646533333964383333396364663166363161616436633734653835 +37316135353065633932656439656165663437373934336237386666663134623362383439653238 +64643664656365303131306266306139353164623935626561643366633330383837373032313838 +33616432643662326430663932353734386634373131633039646237376563393262333838393234 +63376334333862656434313934313965353263363032383261326433643939646464346164313131 +34356361636163616164663432343132343131363533376638656635366436646434373235353831 +65326436616536376533613232636233356164626137343831313065373064336235643535323536 +30323030353639633534313164353835353161653939643638303436396136333033353838633064 +30303233616632303765346137653739343531366134653235323032666630626338646663613762 +62303966323064353765666564333065663331343239653436626430326332316436346632346334 +65646130656331393430656364616161333831363130636438353166613936616165336361373465 +64643839333763346562656661353036333838326235343439316337353937343966303536626133 +63313966306636616334656633616338616334313039653530373566613838393262616663393366 +30396162623163663162633861666663356132653836636664333030646162333737623335363737 +65646233386363636265346438626634376661396236333830356135316234396237643431643761 +33366139663730323934643331633434303365613532656238643934303634636433646261353434 +34306434626439323465393365303737663866306534666534643631636337623666303037353034 +34313839383930313062613634366430353133363739636665353138383034353963633333653765 +36393332383739326136646231363436303765346430373865643866383332343231653235393164 +34663935663365303031376463376665666236666438376536303335653636616331643637633762 +65643139613364623733663362346633316535633261666238363663633166643239356134616439 +31396130356435656132323634393364666238656632633264643132323761366266326136386232 +32373438353538396262373163396431323030633365353765373463643934666638373366663939 +32643061386265316334623764373632346436396336616539333661616335613937613833326165 +61616163366635643630633138323937633332313733363130396365363333383865363731363861 +34396262386333646661613032303239636436313364326631303339613733333039663539306336 +32636661656464353861643937356234313838303737373631633438366161636436363837306131 +33653534623437633061383262346137613437343834633431613664633061313731396263643034 +32643235356532623932656462393234346438383738333933396632656165636661646330653136 +30323366613831623639613062613030363065633161316330663539306436666363386665353132 +34306565623762663461393837653937333039636530613164343066613262373835373837613631 +33636333643664343133343632633333366233356133343436393732393736366637353338633132 +31626432643366373938323530353465383561343734616132353066616565633263396262663965 +32353031323861633239306538666364323063353064396538326136663839346333623630336664 +35366563653831663732363034366632626133326437366339333663376263343030383833643761 +66333438616636653434326139363965343061313262636632316533356261343362313339613036 +31393538383932346432626665383731363434333062633733383638376635633762333735393832 +65303036393139386534663965663562383062356533303462333864613163646235313033613430 +38633338383366383538396535353436643832626637336337313464633464616465663866393437 +63393339336364626138393966616330663531376265356635323335633863653132636561396339 +66383537663966343465306263303739663433613366333730643137303565323963326639336538 +63623864623038666234363837623930616235363338653636623331613463653438633330353662 +61616337396234396633623938383163306230333135383561316333353032363833643934653632 +61373833633237303365666661663265386238363735666234323438623737383231303966613231 +62623237636162666466333437613534356166633061363834663337363934626564333631343435 +31363735353066636233643361323665316538323762643963376166616462313664393664373361 +64663533376532336633633835646266396531343663653036336166326264313965646662636130 +66376637316539666163643537393966376239633761643734316432663165383566303164653135 +33333032343133653066623761316566333831643339323838623465633365333332346534363231 +65353538326265303435353261346362353662623636343438373535633732633331353463326465 +35653539633437373334643233643862383836353163346661616330666166316162616134643462 +36663833353639613561323865306166376236313332313430656238346331346638326239336165 +38353162393539343036386564626639303637626661343838383465396536303536306238333664 +63343539666334393238336134336364333265623438643337363936336531643863366637656436 +31383066316434323136363563616138653761376436323765663031303533373065633032623131 +37646164336332663039656663333735623236393464616436373062333763653361643238643439 +37303738393935346334623466656536666436333636333961316637376363643261393636366436 +31326433663832643264373165343835306535643737316661393661333130666332366161643262 +39623130636163373834333131623136656531623437343161343264373339376262343537343433 +31373839653464636231613436643032316433616661383664383431393065663662386631323161 +31326135373639383034646330303664643864663166653034313237336638303863323266326630 +33376539303730666530633935383531616261373964333633306236626431383734313639313433 +39353737383164346538663931626565666633626232306535663735643864396264323234396130 +38346537326663626330633733646433616462353264623139393835303037313065373935396435 +62633234666135353838303663383464313863626266636165666332373431343438343835386666 +66356534336130303235666439303561343364626263373432303065376263633365663131663436 +36373538343730366236613737353561313133613636656634343961636665366266366633376433 +36626165343632346631633830306134333862346161623630393564653864363435383235343765 +31633435613666653734383038646237376637633665303830636333313863323062623634303761 +34393163646263383739313538656662613136343033363834393535656435633530306266336631 +66303430353636323339383464616131643137373034346266346431323635323862643263366230 +65663864373262666165313339656432643762363064353139663035333037616164663166306163 +64613231383836343263376638366438373839376236663231336663626239396630396364336335 +37313766653233393062313833373631386139346666333239613566393337366461633961636437 +31653034653064373937333962653933653830646435366639396538613665333565363366346335 +61323961383533356462646133626231376666383131633636313639396435396431666663363666 +63373130303966653966663338396561646435613934376566393965376137353730633335663637 +38646336643830303661303337316366333738393634303262306530366361336137343832353037 +33663039643462663462643338326431393833626664343332326362613663663232633538383733 +3263 diff --git a/skillz/host_vars/sk-testvm.yml b/skillz/host_vars/sk-testvm.yml new file mode 100644 index 00000000..9d90f0e6 --- /dev/null +++ b/skillz/host_vars/sk-testvm.yml @@ -0,0 +1,20 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +36343634626466393365306234316131613539323961623538663531396562386132383566393466 +6130363435373732366339353834366363613132663939620a383639346430303738363336623932 +33386534653435666564643632373263653061346139373230633862616234346663396162336362 +3838303063353831380a633633646333326438313338353138616237363131633930613835333936 +66366539613262316463386534353465306664663737343963303137353530643839323737653632 +65666364373864636161363838366531373662343138356665333431616633653663643133666231 +37393132386332356331373938666465636563356662393230393062343363613037336532323662 +63663663326436353665613630623338626166346530393766333432343463343838623538343431 +64353432366231643930336234623831306462303864646430326436313961373430353366313363 +61396564373133626132643533353230633137306461373338643236333261616264313066623965 +31643738353735656234646264346435373533666630613165663331326565353664626231636438 +35343538383964313561303935653664353862653561656334633734626535616661323562396531 +33633832356164623636646430363835356434343266393732623036323235386462363837373366 +39373062323636376661303035653861656563353931383931353137633663316438376434353230 +36653730353337373962393738306462313332393166623162353861373738636362303431663466 +66613733323439383462643661323161383838653634353432636464323564323332386163313961 +35356464646165353130623638373762326135613661643561653036336362373036396336326136 +61623537653532623366616562333635366235663439656137636336323233623133633139396562 +333931343862326637623030306666663235 diff --git a/skillz/host_vars/sk-tomnext-nc.yml b/skillz/host_vars/sk-tomnext-nc.yml new file mode 100644 index 00000000..edc3d87c --- /dev/null +++ b/skillz/host_vars/sk-tomnext-nc.yml @@ -0,0 +1,24 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +36356134653135646230316263303837396362626634666630353766313231383539623464313232 +3664336463343730333532633363393636383132666637320a626332313833313934663262373661 +39353666623762366536656665653039303738633062386439323765336365643366646633326166 +6430393563343136330a636636663066366539313362663665333339313739653064353034363233 +31313465643039616538663462353934313636633531313064656663303866623939623530376537 +61373363663231313566396534623532303562353730383839353830623230313231303362353436 +38313162363237326234376533393132393832333632313532323266346162643364376339393038 +31656566366361336561316165646433653562626432313638323433303130663635626533353562 +34326132626231383136636230353731643031636332323638646364383939376561636532303762 +63386636333032623934366438326362383032646637373133613966393738646232353935643337 +32343661376537323336653433376631383934656265626430383261356135393436663631373062 +30333230666135356361326435353936643531393133653662333262356366323163656439636234 +66383134373631333163386331643062393964336365373535333564396338663430383230343633 +63656338616533636462623261383865393665303738633766396638656131613336343031343431 +65316439333231616662626338323134353535626134656633313662393164326634633432313464 +64396636383333343764653862623665636430346166336234386661393832623962633664616531 +61336564303131643038303333316364616139386435613337303931336235396236373639623437 +34316538326232376463333239643762623562393937663830633530656631376438643432333630 +34326232386263646461613934653938636535303234383130336437373536333832306361663765 +66353763323632313537373235386638636637643462356131386434623165633637343138313133 +62663130363036643437396161623130643431376665383437393230333032336331373938383535 +62666266306265623362376438343931363939613834333066646663633963393763643337306237 +303134316237656561613735633037316534 diff --git a/skillz/host_vars/sk-tomnext.yml b/skillz/host_vars/sk-tomnext.yml new file mode 100644 index 00000000..633b2343 --- /dev/null +++ b/skillz/host_vars/sk-tomnext.yml @@ -0,0 +1,21 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +65643036623938393866636366326163616632373835343732653435663062663830373737353465 +6431653934353539663635343136666334613235326330640a393932333233373533383065333561 +38313961636234636630383835383536313232306130653733643864366535643633363839353030 +3531333730303361330a613761396630316363303537633164656163613765663935306136373565 +31393361316339383463303166396437353961663436393135303138643633373139376361616237 +61323836613639346638393364613539373939646366386565383336373035373535613233383037 +66653532636661643930663335636565666464633364653065363836653666373364356265373763 +31666231306136366139663637343030613432373561343437386231386431366432343633323032 +34356238323038333661323066363035373930303433626131306138353561393239643034633265 +30663536326666643839333662666662343139626265663630626334656161303735646665336565 +30346361343663666635626366636639643536663439363630633439623965373435323634356238 +64666165663061303031323830613565326163393566633231333961303638343662333335363363 +36393066636463303061353636383339333233373936633438306537363765623439343434626465 +31653036653166613035343639333239386333316238383232353463343631656234373138386564 +34316165326239626566623230336537343766373831323566356338313837653330356233353338 +64626232303537356564623165376539323662303431643562636661306163383033313037346337 +36306366613134343032366162303335323731346139303932623130623830646562336234326161 +36633137333439373534383963613239623931326538613362643139353261666262623033303633 +34313230663237326665313232306436653530633439316638623436656363343931373632343230 +63663465336234393866 diff --git a/skillz/host_vars/sk-torrent.yml b/skillz/host_vars/sk-torrent.yml new file mode 100644 index 00000000..ff0933da --- /dev/null +++ b/skillz/host_vars/sk-torrent.yml @@ -0,0 +1,10 @@ +$ANSIBLE_VAULT;1.2;AES256;skillz +34666562643336356334333631623765396463633339383637323365613134643837363366663030 +3066333336333863306539633265356438353437363236640a303134316263383036653364626533 +30636530643563636561336638333235393038303763646166396233363765313539376334383334 +3034313933613162320a346662306463393264306363653239616435336135363834626436386161 +32386238313237623234373330313938333564393435323539363833663136333435663832333538 +30373266623862643131633863376139386634303038333533666562363765663635666362313938 +33626231623535306361343739636464303438396138383738333135306333616535303031306436 +62353061363963633339303162666162383332366434366232353864656630616231366165356439 +3637 diff --git a/skillz/image-generate.yml b/skillz/image-generate.yml new file mode 100644 index 00000000..1b11f1eb --- /dev/null +++ b/skillz/image-generate.yml @@ -0,0 +1,20 @@ +--- +- name: generate os image + hosts: "{{ install_hostnames }}" + connection: local + gather_facts: no + roles: + - role: "installer/{{ install_distro }}/image" + post_tasks: + - pause: + seconds: 0 + prompt: | + The resulting images can be found here: + + {% for host in play_hosts %} + {{ host }}: + {% for image in hostvars[host].output_images %} + - {{ image }} + {% endfor %} + + {% endfor %} diff --git a/skillz/iso-generate.yml b/skillz/iso-generate.yml new file mode 100644 index 00000000..584b8914 --- /dev/null +++ b/skillz/iso-generate.yml @@ -0,0 +1,10 @@ +--- +- name: cook variables for host + hosts: "{{ install_hostnames }}" + gather_facts: no + tasks: + - set_fact: + install: "{{ install | default({}) }}" + network: "{{ network | default({}) }}" + +- import_playbook: ../common/iso-generate.yml diff --git a/skillz/iso-install.yml b/skillz/iso-install.yml new file mode 100644 index 00000000..5defe6d3 --- /dev/null +++ b/skillz/iso-install.yml @@ -0,0 +1,10 @@ +--- +- name: cook variables for host + hosts: "{{ install_hostname }}" + gather_facts: no + tasks: + - set_fact: + install: "{{ install | default({}) }}" + network: "{{ network | default({}) }}" + +- import_playbook: ../common/iso-install.yml diff --git a/skillz/openwrt-deploy.yml b/skillz/openwrt-deploy.yml new file mode 100644 index 00000000..e7cc49fa --- /dev/null +++ b/skillz/openwrt-deploy.yml @@ -0,0 +1,9 @@ +--- +- name: generate os image + hosts: "{{ install_hostname }}" + connection: local + gather_facts: no + roles: + - role: installer/openwrt/image + +- import_playbook: ../common/openwrt-deploy.yml diff --git a/skillz/sk-2019.yml b/skillz/sk-2019.yml new file mode 100644 index 00000000..3d555ba5 --- /dev/null +++ b/skillz/sk-2019.yml @@ -0,0 +1,139 @@ +--- +- name: Basic Setup + hosts: sk-2019 + roles: + # - role: apt-repo/base + # - role: core/base + # - role: core/sshd/base + # - role: core/zsh + - role: core/cpu-microcode + # - role: core/users + - role: storage/luks/base + - role: storage/zfs/base + - role: apt-repo/spreadspace + - role: storage/zfs/sanoid + tasks: + - name: install post-boot script + copy: + dest: /usr/local/bin/post-boot + mode: 0755 + content: | + #!/bin/bash + set -e + + {% for name, volume in luks_devices.items() %} + echo -e "opening crypto volume: \033[1;37m{{ name }}\033[0m" + cryptsetup luksOpen '{{ volume.device }}' '{{ name }}' + {% endfor %} + + systemctl restart zfs-import-cache.service + systemctl restart zfs-mount.service + systemctl restart zfs-share.service + systemctl restart zfs-zed.service + mount -a + + sleep 2 + systemctl restart mariadb.service + systemctl restart apache2.service + + - name: install ispconfig fix systemd service unit + copy: + dest: /etc/systemd/system/fix-fstab.service + content: | + [Unit] + Description=fix fstab entries made by ispconfig + + [Service] + Type=oneshot + ExecStart=/usr/bin/sed s/bind,nobootwait/bind,nofail/ -i /etc/fstab + + - name: install ispconfig fix systemd service unit + copy: + dest: /etc/systemd/system/fix-fstab.timer + content: | + [Unit] + Description=fix fstab entries made by ispconfig + + [Timer] + OnCalendar=*-*-* *:*:00 + + [Install] + WantedBy=timers.target + + - name: enable and start fstab fix + systemd: + name: fix-fstab.timer + daemon_reload: yes + enabled: yes + state: started + + ### the machine reboots often - make it so that no manual intervention is necessary + ### of course this makes encrypting the disks a little bit silly... + - name: create base dir for crypto volume key files + file: + path: /etc/cryptsetup-keys.d/ + state: directory + mode: 0500 + + - name: generate key files for crypto volumes + loop: "{{ luks_devices | dict2items }}" + loop_control: + label: "{{ item.key }}" + copy: + dest: "/etc/cryptsetup-keys.d/{{ item.key }}.key" + content: "{{ item.value.passphrase }}" + mode: 0400 + notify: rebuild initramfs + + - name: generate crypttab + copy: + dest: /etc/crypttab + content: | + # ansible generated + {% for name, volume in luks_devices.items() %} + {{ name }} {{ volume.device }} /etc/cryptsetup-keys.d/{{ name }}.key luks + {% endfor %} + notify: rebuild initramfs + + handlers: + - name: rebuild initramfs + command: dpkg-reconfigure initramfs-tools + + +### TODO: +# +# zfs create -o quota=30G -o compress=lz4 storage/mysql +# zfs create -o quota=35G -o compress=lz4 storage/automysqlbackup +# zfs create -o quota=300G -o compress=lz4 storage/vmail +# zfs create -o quota=600G -o compress=lz4 storage/www +# zfs create -o quota=40G -o compress=lz4 storage/log +# zfs create -o quota=50G -o compress=lz4 storage/configz +# zfs create -o quota=20G -o compress=lz4 storage/backup +# +# mkdir -p /var/lib/mysql /var/lib/automysqlbackup /var/vmail /var/www /var/log/ispconfig /var/backup +# chmod 0000 /var/lib/mysql /var/lib/automysqlbackup /var/vmail /var/www /var/log/ispconfig /var/backup +# chattr +i /var/lib/mysql /var/lib/automysqlbackup /var/vmail /var/www /var/log/ispconfig /var/backup +# +### add to /etc/fstab: +## +## /srv/storage/mysql /var/lib/mysql none defaults,bind,x-systemd.automount,nofail 0 0 +## /srv/storage/automysqlbackup /var/lib/automysqlbackup none defaults,bind,x-systemd.automount,nofail 0 0 +## /srv/storage/vmail /var/vmail none defaults,bind,x-systemd.automount,nofail 0 0 +## /srv/storage/www /var/www none defaults,bind,x-systemd.automount,nofail 0 0 +## /srv/storage/log /var/log/ispconfig none defaults,bind,x-systemd.automount,nofail 0 0 +## /srv/storage/backup /var/backup none defaults,bind,x-systemd.automount,nofail 0 0 +# +# mount -a +# + + +########### manual post-boot + +# cat /etc/fstab | grep "^/var/log" | awk '{ system("umount "$2) }' +# umount /srv/storage/www/clients/client2/web2/web/shared/fileadmin/wolke +# umount /srv/storage/www/clients/client2/web2/web/shared/fileadmin/wolke +# umount /srv/storage/www/clients/client2/web2/web/shared/fileadmin/wolke +# mount | grep systemd-1 | awk '{ print($3) }' | grep "^/var" | xargs umount +# mount | grep systemd-1 | awk '{ print($3) }' | grep "^/var" | xargs umount +# mount | grep systemd-1 | awk '{ print($3) }' | grep "^/var" | xargs umount +# rm -rf /srv/storage/* diff --git a/skillz/sk-2019vm.yml b/skillz/sk-2019vm.yml new file mode 100644 index 00000000..d7c42245 --- /dev/null +++ b/skillz/sk-2019vm.yml @@ -0,0 +1,39 @@ +--- +- name: Basic Setup + hosts: sk-2019vm + roles: + - role: apt-repo/base + - role: core/base + - role: core/sshd/base + - role: core/zsh + - role: core/cpu-microcode + - role: core/users + - role: storage/luks/base + - role: storage/zfs/base + - role: storage/zfs/sanoid + - role: vm/host/base + - role: vm/host/network + - role: installer/debian/base + tasks: + - name: install post-boot script + copy: + dest: /usr/local/bin/post-boot + mode: 0755 + content: | + #!/bin/bash + set -e + + {% for name, volume in luks_devices.items() %} + echo -e "opening crypto volume: \033[1;37m{{ name }}\033[0m" + cryptsetup luksOpen '{{ volume.device }}' '{{ name }}' + {% endfor %} + + systemctl restart zfs-import-cache.service + systemctl restart zfs-mount.service + systemctl restart zfs-share.service + systemctl restart zfs-zed.service + mount -a + + sleep 2 + rm -f /run/libvirt/qemu/autostarted + systemctl restart libvirtd.service diff --git a/skillz/sk-2024.yml b/skillz/sk-2024.yml new file mode 100644 index 00000000..a16cff2a --- /dev/null +++ b/skillz/sk-2024.yml @@ -0,0 +1,43 @@ +--- +- name: Basic Setup + hosts: sk-2024 + roles: + - role: apt-repo/base + - role: core/base + - role: core/sshd/base + - role: core/zsh + - role: core/ntp + - role: core/cpu-microcode + +- name: Payload Setup + hosts: sk-2024 + roles: + - role: storage/luks/base + - role: storage/zfs/base + - role: storage/zfs/sanoid + - role: vm/host/base + - role: vm/host/network + - role: installer/debian/base + tasks: + - name: install post-boot script + copy: + dest: /usr/local/bin/post-boot + mode: 0755 + content: | + #!/bin/bash + set -e + + {% for name, volume in luks_devices.items() %} + echo -e "opening crypto volume: \033[1;37m{{ name }}\033[0m" + cryptsetup luksOpen '{{ volume.device }}' '{{ name }}' + {% endfor %} + + systemctl restart zfs-import-cache.service + systemctl restart zfs-mount.service + systemctl restart zfs-share.service + systemctl restart zfs-zed.service + mount -a + + sleep 2 + rm -f /run/libvirt/qemu/autostarted + systemctl restart libvirtd.service diff --git a/skillz/sk-cloudio.yml b/skillz/sk-cloudio.yml new file mode 100644 index 00000000..a0ff8f51 --- /dev/null +++ b/skillz/sk-cloudio.yml @@ -0,0 +1,36 @@ +--- +- name: Basic Setup + hosts: sk-cloudio + roles: + - role: apt-repo/base + - role: core/base + - role: core/sshd/base + - role: core/zsh + - role: core/ntp + +- name: Infra + hosts: sk-cloudio + roles: + - role: core/users + - role: storage/zfs/base + - role: apt-repo/spreadspace + - role: storage/zfs/sanoid + - role: kubernetes/base + - role: kubernetes/standalone/base + - role: x509/static-ca/base + - role: x509/acmetool/base + - role: nginx/base + - role: apps/publish/base + - role: mail/postfix/base + +- name: Apps + hosts: sk-cloudio + roles: + - role: apps/nextcloud +# - role: apps/collabora/code + - role: apps/onlyoffice + +# - role: apps/coturn +# - role: apps/jitsi/meet +# - role: apps/wikijs +# - role: apps/keycloak diff --git a/skillz/sk-testvm.yml b/skillz/sk-testvm.yml new file mode 100644 index 00000000..74ba2053 --- /dev/null +++ b/skillz/sk-testvm.yml @@ -0,0 +1,151 @@ +--- +- name: Basic Setup + hosts: sk-testvm + roles: + - role: apt-repo/base + - role: core/base + - role: core/sshd/base + - role: core/zsh + - role: core/ntp + +- name: Payload Setup + hosts: sk-testvm + vars: + acme_client: uacme + # acme_client: acmetool + # cert_provider: "{{ acme_client }}" + # cert_provider: static + # cert_provider: selfsigned + cert_provider: static-ca + roles: + - role: apt-repo/spreadspace + - role: kubernetes/base + - role: kubernetes/standalone/base + - role: "x509/{{ cert_provider }}/base" + - role: nginx/base + - role: nginx/auth/sso/base + - role: nginx/auth/sso/backend + - role: nginx/vhost + nginx_vhost: + default: yes + name: nosuchsite + template: generic + tls: + certificate_provider: "{{ cert_provider }}" + certificate_config: "{{ lookup('vars', (cert_provider | replace('-','_'))+'_cert_config__default', default={}) }}" + hsts: no + hostnames: + - testvm.elev8.at + locations: + '/': + root: /var/www/default + index: index.html + - role: nginx/vhost + nginx_vhost: + name: login + template: generic + tls: + certificate_provider: "{{ cert_provider }}" + certificate_config: "{{ lookup('vars', (cert_provider | replace('-','_'))+'_cert_config__test', default={}) }}" + hsts: no + hostnames: + - login.spreadspace.org + - login.spreadspace.com + - login.spreadspace.net + - login.spreadspace.systems + locations: + '/': + proxy_pass: http://127.0.0.1:8082 + - role: nginx/vhost + nginx_vhost: + name: test + template: generic + tls: + certificate_provider: "{{ cert_provider }}" + certificate_config: "{{ lookup('vars', (cert_provider | replace('-','_'))+'_cert_config__test', default={}) }}" + hsts: no + hostnames: + - test.spreadspace.org + - test.spreadspace.com + - test.spreadspace.net + - test.spreadspace.systems + extra_directives: | + include snippets/sso-spreadspace.conf; + locations: + '/': + # proxy_pass: http://127.0.0.1:8080 + root: /var/www/test + index: index.html + extra_directives: | + #auth_request_set $username $upstream_http_x_username; + #proxy_set_header Remote-User $username; + auth_request_set $cookie $upstream_http_set_cookie; + add_header Set-Cookie $cookie; + # - role: apps/mumble + # mumble_version: v1.4.287-4 + # mumble_instance: spreadspace + # mumble_hostnames: + # - test.spreadspace.org + # - test.spreadspace.com + # - test.spreadspace.net + # - test.spreadspace.systems + # mumble_superuser_password: "very-secret" + # mumble_config_options: + # bonjour: false + # sslCiphers: "ECDHE+AESGCM:DHE+AESGCM:ECDHE+AES256:DHE+AES256:ECDHE+AES128:DHE+AES128:!RSA:!ADH:!AECDH:!MD5" + # welcometext: "Welcome to the spreadspace Mumble Test-Server" + # rememberchannel: true + # mumble_tls: + # certificate_provider: "{{ cert_provider }}" + # certificate_config: "{{ lookup('vars', cert_provider+'_cert_config__test', default={}) }}" + # - role: apps/coturn + # coturn_version: 4.6.2-r4 + # coturn_realm: spreadspace + # coturn_hostnames: + # - test.spreadspace.org + # - test.spreadspace.com + # - test.spreadspace.net + # - test.spreadspace.systems + # coturn_auth_secret: "somewhat-secret" + # coturn_tls: + # certificate_provider: "{{ cert_provider }}" + # certificate_config: "{{ lookup('vars', cert_provider+'_cert_config__test', default={}) }}" + post_tasks: + - name: make sure document root directories exist + loop: + - test + - default + file: + path: "/var/www/{{ item }}" + state: directory + + - name: install index.html for default server + copy: + dest: /var/www/default/index.html + content: | + <html> + <head> + <title>No Such Site</title> + </head> + <body style="font-family: Helvetica, Arial, Sans-Serif; color: white; background: black;"> + <div style="text-align: center; margin-top: 4em; margin-left:auto; margin-right:auto;"> + <h2 style="">You have reached testvm.elev8.at, nothing to see here.</h2> + </div> + </body> + </html> + + + - name: install index.html for test server + copy: + dest: /var/www/test/index.html + content: | + <html> + <head> + <title>This is Test</title> + </head> + <body style="font-family: Helvetica, Arial, Sans-Serif; color: white; background: black;"> + <div style="text-align: center; margin-top: 4em; margin-left:auto; margin-right:auto;"> + <h2 style="">If you can read this the test was successful.</h2> + </div> + </body> + </html> diff --git a/skillz/sk-tomnext-hp.yml b/skillz/sk-tomnext-hp.yml new file mode 100644 index 00000000..b0c38093 --- /dev/null +++ b/skillz/sk-tomnext-hp.yml @@ -0,0 +1,6 @@ +--- +- name: do nothing + hosts: sk-tomnext-hp + tasks: + - debug: + msg: this host is not managed by ansible ... nothing to do here diff --git a/skillz/sk-tomnext-nc.yml b/skillz/sk-tomnext-nc.yml new file mode 100644 index 00000000..fbc7aeb0 --- /dev/null +++ b/skillz/sk-tomnext-nc.yml @@ -0,0 +1,28 @@ +--- +- name: Basic Setup + hosts: sk-tomnext-nc + tasks: + - debug: + msg: "this is a legacy host please use branch legacy/skillz" +# roles: +# - role: apt-repo/base +# - role: core/base +# - role: core/sshd/base +# - role: core/zsh +# +#- name: Payload Setup +# hosts: sk-tomnext-nc +# roles: +# - role: core/users +# - role: storage/zfs/base +# - role: apt-repo/spreadspace +# - role: storage/zfs/sanoid +# - role: kubernetes/base +# - role: kubernetes/standalone/base +# - role: x509/acmetool/base +# - role: nginx/base +# - role: mail/postfix/base +# - role: apps/nextcloud +# - role: apps/collabora/code +# - role: apps/onlyoffice +# diff --git a/skillz/sk-tomnext.yml b/skillz/sk-tomnext.yml new file mode 100644 index 00000000..8ad69918 --- /dev/null +++ b/skillz/sk-tomnext.yml @@ -0,0 +1,39 @@ +--- +- name: Basic Setup + hosts: sk-tomnext + roles: + - role: apt-repo/base + - role: core/base + - role: core/sshd/base + - role: core/zsh + - role: core/cpu-microcode + - role: core/users + - role: storage/luks/base + - role: storage/zfs/base + - role: storage/zfs/sanoid + - role: vm/host/base + - role: vm/host/network + - role: installer/debian/base + tasks: + - name: install post-boot script + copy: + dest: /usr/local/bin/post-boot + mode: 0755 + content: | + #!/bin/bash + set -e + + {% for name, volume in luks_devices.items() %} + echo -e "opening crypto volume: \033[1;37m{{ name }}\033[0m" + cryptsetup luksOpen '{{ volume.device }}' '{{ name }}' + {% endfor %} + + systemctl restart zfs-import-cache.service + systemctl restart zfs-mount.service + systemctl restart zfs-share.service + systemctl restart zfs-zed.service + mount -a + + sleep 2 + rm -f /run/libvirt/qemu/autostarted + systemctl restart libvirtd.service diff --git a/skillz/sk-torrent.yml b/skillz/sk-torrent.yml new file mode 100644 index 00000000..e6a176c1 --- /dev/null +++ b/skillz/sk-torrent.yml @@ -0,0 +1,10 @@ +--- +- name: Basic Setup + hosts: sk-torrent + roles: + - role: apt-repo/base + - role: core/base + - role: core/sshd/base + - role: core/zsh + - role: core/users + - role: skillz/torrent diff --git a/skillz/usb-generate.yml b/skillz/usb-generate.yml new file mode 100644 index 00000000..7f633f1e --- /dev/null +++ b/skillz/usb-generate.yml @@ -0,0 +1,10 @@ +--- +- name: cook variables for host + hosts: "{{ install_hostnames }}" + gather_facts: no + tasks: + - set_fact: + install: "{{ install | default({}) }}" + network: "{{ network | default({}) }}" + +- import_playbook: ../common/usb-generate.yml diff --git a/skillz/usb-install.yml b/skillz/usb-install.yml new file mode 100644 index 00000000..0f62bc85 --- /dev/null +++ b/skillz/usb-install.yml @@ -0,0 +1,10 @@ +--- +- name: cook variables for host + hosts: "{{ install_hostname }}" + gather_facts: no + tasks: + - set_fact: + install: "{{ install | default({}) }}" + network: "{{ network | default({}) }}" + +- import_playbook: ../common/usb-install.yml diff --git a/skillz/vm-deploy.yml b/skillz/vm-deploy.yml new file mode 100644 index 00000000..8530b14a --- /dev/null +++ b/skillz/vm-deploy.yml @@ -0,0 +1,18 @@ +--- +- name: generate os image + hosts: "{{ install_hostname }}" + connection: local + gather_facts: no + roles: + - role: "installer/{{ install_distro }}/image" + +- name: cook variables for host + hosts: "{{ install_hostname }}" + gather_facts: no + tasks: + - set_fact: + install: "{{ install | default({}) }}" + network: "{{ network | default({}) }}" + vm_host: "{{ vm_host | default({}) }}" + +- import_playbook: ../common/vm-deploy.yml diff --git a/skillz/vm-install.yml b/skillz/vm-install.yml new file mode 100644 index 00000000..da6a29a5 --- /dev/null +++ b/skillz/vm-install.yml @@ -0,0 +1,11 @@ +--- +- name: cook variables for host + hosts: "{{ install_hostname }}" + gather_facts: no + tasks: + - set_fact: + install: "{{ install | default({}) }}" + network: "{{ network | default({}) }}" + vm_host: "{{ vm_host | default({}) }}" + +- import_playbook: ../common/vm-install.yml |