...
 
Commits (9)
...@@ -40,4 +40,4 @@ Possible fixes ...@@ -40,4 +40,4 @@ Possible fixes
(If you can, link to the line of code that might be responsible for the problem) (If you can, link to the line of code that might be responsible for the problem)
/label ~bug /label ~bug
/cc @gethmann /cc @vn4918
- hosts: dhcpd - hosts: dhcpd
vars:
- dhcpd:
domain: las.kit.edu
subnet: 129.13.108.0
netmask: 255.255.255.0
range_start: 129.13.108.74
range_end: 129.13.108.89
routers: 129.13.108.254
broadcast: 129.13.255.255
host_list: host-list-las
roles: roles:
- dhcpd - dhcpd
ansible_user: bernhard ansible_user: root
ansible_ssh_user: root
user_account: bernhard user_account: bernhard
ip_suffix: 70 ip_suffix: 70
loc: 622 loc: 601
os: Fedora 29 os: Fedora 31
computer_name: majestix computer_name: majestix
- hosts: lab - hosts: lab
vars:
- dhcpd:
domain: maglab
subnet: 192.168.0.0
netmask: 255.255.255.0
range_start: 192.168.0.1
range_end: 192.168.0.100
routers: 192.168.0.10
broadcast: 192.168.0.255
host_list: host-list-maglab
roles: roles:
- lab - dhcpd
- lab
---
- include: common.yml
- include: clients.yml
tags: client
- include: lasarchiv.yml
- include: opera.yml
- include: desktop.yml
- include: elegant.yml
- include: epics.yml
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
copy: copy:
src: automatic.conf src: automatic.conf
dest: /etc/dnf/automatic.conf dest: /etc/dnf/automatic.conf
mode: 644 mode: 0644
owner: root owner: root
group: root group: root
when: ansible_distribution == "Fedora" when: ansible_distribution == "Fedora"
......
--- ---
- name: dhcpd installed - name: Load OS dependent variables
include_vars: '{{ item }}'
with_first_found:
- files:
- 'vars/{{ ansible_os_family }}.yml'
errors: ignore
tags: dhcpd
- name: dhcpd installed (Debian)
become: true become: true
dnf: package:
name: dhcp name: "{{ pkg_name }}"
state: installed state: present
notify: notify:
- start dhcpd - start dhcpd
- enable dhcpd - enable dhcpd
...@@ -11,17 +19,15 @@ ...@@ -11,17 +19,15 @@
- name: copy mac addresses and config - name: copy mac addresses and config
become: true become: true
copy: copy:
src: "{{ item }}" src: "{{ dhcpd.host_list }}"
dest: "/etc/dhcp/{{ item }}" dest: "/etc/dhcp/{{ dhcpd.host_list }}"
backup: yes backup: yes
owner: root owner: dhcpd
group: root group: dhcpd
validate: /sbin/dhcpd -t -cf %s mode: 0644
validate: "{{ bin_path }} -t -cf %s"
decrypt: yes decrypt: yes
notify: restart dhcpd notify: restart dhcpd
with_items:
- "host-list-las"
- dhcpd.conf
- name: install dhcpd config - name: install dhcpd config
become: true become: true
...@@ -29,5 +35,8 @@ ...@@ -29,5 +35,8 @@
src: dhcpd.j2 src: dhcpd.j2
dest: /etc/dhcp/dhcpd.conf dest: /etc/dhcp/dhcpd.conf
backup: yes backup: yes
validate: /sbin/dhcpd -t -cf %s owner: dhcpd
group: dhcpd
mode: 0644
validate: "{{ bin_path }} -t -cf %s"
notify: restart dhcpd notify: restart dhcpd
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
# #
# option definitions common to all supported networks... # option definitions common to all supported networks...
option domain-name "las.kit.edu"; option domain-name "{{ dhcpd.domain }}";
option domain-name-servers 129.13.64.5, 129.13.96.2; option domain-name-servers 129.13.64.5, 129.13.96.2;
default-lease-time 60; default-lease-time 60;
...@@ -25,6 +25,7 @@ authoritative; ...@@ -25,6 +25,7 @@ authoritative;
# have to hack syslog.conf to complete the redirection). # have to hack syslog.conf to complete the redirection).
log-facility local7; log-facility local7;
{% if failover %}
# failover https://www.madboa.com/geek/dhcp-failover/ # failover https://www.madboa.com/geek/dhcp-failover/
# https://kb.isc.org/article/AA-00502/0/A-Basic-Guide-to-Configuring-DHCP-Failover.html # https://kb.isc.org/article/AA-00502/0/A-Basic-Guide-to-Configuring-DHCP-Failover.html
failover peer "dhcp-failover" { failover peer "dhcp-failover" {
...@@ -51,20 +52,24 @@ failover peer "dhcp-failover" { ...@@ -51,20 +52,24 @@ failover peer "dhcp-failover" {
split 128; split 128;
{% endif %} {% endif %}
} }
{% endif %}
# A slightly different configuration for an internal subnet. # A slightly different configuration for an internal subnet.
subnet 129.13.108.0 netmask 255.255.255.0 { subnet {{ dhcpd.subnet }} netmask {{ dhcpd.netmask }} {
option routers 129.13.108.254; option routers {{ dhcpd.routers }};
option broadcast-address 129.13.255.255; option broadcast-address {{ dhcpd.broadcast }};
option domain-name "las.kit.edu"; option domain-name "{{ dhcpd.domain }}";
option domain-name-servers 129.13.64.5, 129.13.96.2; option domain-name-servers 129.13.64.5, 129.13.96.2;
#
default-lease-time 1800;
max-lease-time 7200;
deny unknown-clients;
range {{ dhcpd.range_start }} {{ dhcpd.range_end }};
{% if failover %}
pool { pool {
failover peer "dhcp-failover"; failover peer "dhcp-failover";
default-lease-time 1800;
max-lease-time 7200;
range 129.13.108.70 129.13.108.89;
deny unknown-clients;
} }
{% endif %}
} }
include "/etc/dhcp/host-list-las"; include "/etc/dhcp/{{ dhcpd.host_list }}";
---
service_name: isc-dhcp-server
pkg_name: isc-dhcp-server
bin_path: /usr/sbin/dhcpd
---
service_name: dhcpd
pkg_name: dhcp
bin_path: /sbin/dhcpd
...@@ -6,6 +6,6 @@ ...@@ -6,6 +6,6 @@
state: present state: present
when: ansible_distribution == 'Fedora' and (ansible_distribution_major_version|int) == item.key|int when: ansible_distribution == 'Fedora' and (ansible_distribution_major_version|int) == item.key|int
with_dict: "{{ pythonsdds_version }}" with_dict: "{{ pythonsdds_version }}"
tags: tags:
- elegant - elegant
- python - python
GIMP Palette
Name: KITcolors
#
0 0 0 #000000
255 255 255 #FFFFFF
0 150 130 #009682
35 161 224 #23A1E0
70 100 170 #4664AA
76 181 167 #4CB5A7
77 77 77 #4D4D4D
125 146 195 #7D92C3
127 202 192 #7FCAC0
128 128 128 #808080
140 182 60 #8CB63C
162 34 35 #A22223
162 177 212 #A2B1D4
163 16 124 #A3107C
167 130 46 #A7822E
178 178 178 #B2B2B2
178 223 217 #B2DFD9
199 208 229 #C7D0E5
217 217 217 #D9D9D9
217 239 236 #D9EFEC
223 155 27 #DF9B1B
227 232 242 #E3E8F2
252 229 0 #FCE500
...@@ -5,3 +5,10 @@ ...@@ -5,3 +5,10 @@
name: "{{ item }}" name: "{{ item }}"
state: present state: present
with_items: "{{ graphics_software }}" with_items: "{{ graphics_software }}"
- name: Copy KIT Inkscape palette to its location
become: yes
copy:
src: KITcolors.gpl
dest: /usr/share/inkscape/palettes/KITcolors.gpl
mode: 0644
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
clone: yes clone: yes
depth: 1 depth: 1
dest: /usr/local/Inovesa dest: /usr/local/Inovesa
version: HEAD version: "HEAD"
- name: cmake Inovesa - name: cmake Inovesa
become: yes become: yes
......
...@@ -6,15 +6,6 @@ ...@@ -6,15 +6,6 @@
name: ["freeipa-client", "sssd"] name: ["freeipa-client", "sssd"]
state: installed state: installed
# - name: add ipa hosts to etc
# become: yes
# lineinfile:
# line: "{{ ipa_host_ip }} {{ ipa_host }}"
# path: /etc/hosts
# state: present
# backup: yes
# insertbefore: BOF
# TODO # TODO
# - name: copy server cert # - name: copy server cert
# copy: # copy:
......
This diff is collapsed.
--- ---
- name: Load OS dependent variables
include_vars: '{{ item }}'
with_first_found:
- files:
- 'vars/{{ ansible_os_family }}.yml'
errors: ignore
tags: dhcpd
- name: dhcpd installed (Debian)
become: true
apt:
name: "{{ pkg_name }}"
state: present
notify:
- start dhcpd
- enable dhcpd
when: ansible_os_family == "Debian"
- name: dhcpd installed (RedHat)
become: true
dnf:
name: "{{ pkg_name }}"
state: present
notify:
- start dhcpd
- enable dhcpd
when: ansible_distribution == "Fedora"
- name: copy mac addresses and config
become: true
copy:
src: "{{ item }}"
dest: "/etc/dhcp/{{ item }}"
backup: yes
owner: dhcpd
group: dhcpd
mode: 0644
decrypt: yes
# https://superuser.com/questions/1286948/ansible-template-validation-fails-on-isc-dhcp-server
# validate: "{{ bin_path }} -t -cf %s"
notify: restart dhcpd
with_items:
- "host-list-maglab"
- dhcpd.conf
- name: set host in hosts file - name: set host in hosts file
lineinfile: lineinfile:
path: /etc/hosts path: /etc/hosts
......
...@@ -7,7 +7,19 @@ ...@@ -7,7 +7,19 @@
- name: install dependencies - name: install dependencies
dnf: dnf:
name: ["texlive-a0poster", "texlive-beamer", "texlive-bophook", "texlive-boxedminipage", "texlive-dinbrief", "texlive-hyperref", "texlive-lettrine", "texlive-mathpazo", "texlive-rcs", "texlive-sciposter", "texlive-shadow", "texlive-pgf", "texlive-xcolor",] name: ["texlive-a0poster",
"texlive-beamer",
"texlive-bophook",
"texlive-boxedminipage",
"texlive-dinbrief",
"texlive-hyperref",
"texlive-lettrine",
"texlive-mathpazo",
"texlive-rcs",
"texlive-sciposter",
"texlive-shadow",
"texlive-pgf",
"texlive-xcolor",]
state: present state: present
skip_broken: yes skip_broken: yes
become: yes become: yes
......
...@@ -4,12 +4,6 @@ ...@@ -4,12 +4,6 @@
path: "{{ texpath }}/fonts/map/vtex/ua1.ali" path: "{{ texpath }}/fonts/map/vtex/ua1.ali"
register: arial register: arial
# - name: temporary directory
# file:
# path: /tmp/arial
# state: directory
# when: arial.stat.isreg
- name: download uarial - name: download uarial
become: yes become: yes
unarchive: unarchive:
...@@ -17,7 +11,7 @@ ...@@ -17,7 +11,7 @@
dest: /tmp dest: /tmp
creates: /tmp/arial creates: /tmp/arial
remote_src: yes remote_src: yes
when: arial.stat.isreg == false when: not arial.stat.isreg
- name: create missing directories - name: create missing directories
become: yes become: yes
...@@ -33,8 +27,8 @@ ...@@ -33,8 +27,8 @@
- fonts/map/vtex - fonts/map/vtex
- dvips/config - dvips/config
- doc/fonts - doc/fonts
when: arial.stat.isreg == false when: not arial.stat.isreg
notify: notify:
- update latex - update latex
- name: move afm, tfm, type1, vf dirs - name: move afm, tfm, type1, vf dirs
...@@ -42,13 +36,13 @@ ...@@ -42,13 +36,13 @@
copy: copy:
src: "/tmp/arial/{{ item }}/" src: "/tmp/arial/{{ item }}/"
dest: "{{ texpath }}/fonts/{{ item }}/urw/arial" dest: "{{ texpath }}/fonts/{{ item }}/urw/arial"
with_items: with_items:
- afm - afm
- tfm - tfm
- type1 - type1
- vf - vf
when: arial.stat.isreg == false when: not arial.stat.isreg
notify: notify:
- update latex - update latex
- name: copy latex dir - name: copy latex dir
...@@ -56,8 +50,8 @@ ...@@ -56,8 +50,8 @@
copy: copy:
src: /tmp/arial/latex/ src: /tmp/arial/latex/
dest: "{{ texpath }}/tex/latex/ua1" dest: "{{ texpath }}/tex/latex/ua1"
when: arial.stat.isreg == false when: not arial.stat.isreg
notify: notify:
- update latex - update latex
- name: copy map dir - name: copy map dir
...@@ -69,11 +63,11 @@ ...@@ -69,11 +63,11 @@
- { from: "map/ua1.map", to: "dvips/config" } - { from: "map/ua1.map", to: "dvips/config" }
- { from: "map/ua1.map", to: "fonts/map/dvips/ua1" } - { from: "map/ua1.map", to: "fonts/map/dvips/ua1" }
- { from: "map/ua1.ali", to: "fonts/map/vtex" } - { from: "map/ua1.ali", to: "fonts/map/vtex" }
when: arial.stat.isreg == false when: not arial.stat.isreg
notify: notify:
- update latex - update latex
- name: copy docu - name: copy docu
become: yes become: yes
copy: copy:
src: "/tmp/arial/{{ item }}" src: "/tmp/arial/{{ item }}"
...@@ -81,7 +75,7 @@ ...@@ -81,7 +75,7 @@
with_items: with_items:
- doc/ - doc/
- README - README
when: arial.stat.isreg == false when: not arial.stat.isreg
notify: notify:
- update latex - update latex
...@@ -92,6 +86,6 @@ ...@@ -92,6 +86,6 @@
command: updmap-sys --enable Map ua1.map command: updmap-sys --enable Map ua1.map
args: args:
chdir: "{{ texpath }}" chdir: "{{ texpath }}"
when: arial.stat.isreg == false when: not arial.stat.isreg
notify: notify:
- update latex - update latex
--- ---
- name: Add chmod-daemon to crontab - name: Add chmod daemon to crontab
become: yes become: yes
crontab: cron:
backup: yes backup: yes
disabled: no disabled: no
day: "*" day: "*"
......
--- ---
#- import_tasks: nfsd.yml # - import_tasks: nfsd.yml
#- import_tasks: data.yml # - import_tasks: data.yml
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
src: /mnt/las-archiv1/system/Opera/18/Opera_RHEL7.tar.bz src: /mnt/las-archiv1/system/Opera/18/Opera_RHEL7.tar.bz
dest: /tmp dest: /tmp
remote_src: yes remote_src: yes
when: stat_result.stat.exists == False when: not stat_result.stat.exists
- name: unzip Opera - name: unzip Opera
become: yes become: yes
...@@ -50,16 +50,20 @@ ...@@ -50,16 +50,20 @@
- { dest: 'libicui18n.so.50', src: 'libicui18n.so.50.1.2' } - { dest: 'libicui18n.so.50', src: 'libicui18n.so.50.1.2' }
- { dest: 'libicuuc.so.50', src: 'libicuuc.so.50.1.2' } - { dest: 'libicuuc.so.50', src: 'libicuuc.so.50.1.2' }
- { dest: 'libicudata.so.50', src: 'libicudata.so.50.1.2' } - { dest: 'libicudata.so.50', src: 'libicudata.so.50.1.2' }
- { src: 'libhwloc.so.5.7.5', dest: 'libhwloc.so.5.7.5' }
when: (ansible_distribution == "Fedora" and (ansible_distribution_major_version|int) >= 22) when: (ansible_distribution == "Fedora" and (ansible_distribution_major_version|int) >= 22)
- name: Link missing/too new libs on Fedora 31 - name: Copy missing/too new libs on Fedora 31
become: yes become: yes
file: copy:
src: "/usr/lib64/{{ item.src }}" src: "{{ opera_path }}/CentOS7libs/{{ item.src }}"
dest: "/usr/lib64/{{ item.dest }}" dest: "/usr/lib64/{{ item.dest }}"
state: link remote_src: yes
mode: 0755
owner: root
group: root
with_items: with_items:
- { src: 'libhwloc.so.15', dest: 'libhwloc.so.5' } - { src: 'libhwloc.so.5.7.5', dest: 'libhwloc.so.5' }
when: (ansible_distribution == "Fedora" and (ansible_distribution_major_version|int) == 31) when: (ansible_distribution == "Fedora" and (ansible_distribution_major_version|int) == 31)
- name: make CentOS7 libs available - name: make CentOS7 libs available
......
--- ---
- name: Software for dependency installation - name: Software for dependency installation
dnf: dnf:
name: ["gcc", "gcc-c++", "glibc-devel.x86_64", "openssl-devel", "python-devel", "lapack-devel", "numpy-f2py", "redhat-rpm-config", "python3-tkinter", "libxcrypt-compat"] name: ["gcc",
"gcc-c++",
"glibc-devel.x86_64",
"openssl-devel",
"python-devel",
"lapack-devel",
"numpy-f2py",
"redhat-rpm-config",
"python3-tkinter",
"libxcrypt-compat"]
state: present state: present
become: yes become: yes
when: ansible_distribution == 'Fedora' when: ansible_distribution == 'Fedora'
......
# $Ansible managed: /etc/ssh/ssh_config.d/06-rpi.conf
Host pi
User pi
HostName 192.168.127.5
ForwardX11 yes
$ANSIBLE_VAULT;1.1;AES256
62333066643230656432666638356532316637393032373566373865636531373965646164373363
3533643033376535323839646665323536303833626634640a303330306366373335393037303833
65653263346538613831353866643664633936626536623739303262346433336135623431373532
3662616561346638380a333230386562333833653935623366306261393232366531316262623865
61376138376361346365653730646533656136393138333231343033333464346232373834303735
32313661613937306438646262353233323463613964653664636435323438666236333232623962
32356337303231303732383034626166353837623965323931643432633962363130636239343965
62613563666639623566363663623962333862333161646561383062376530313233623834323533
63383430633637383639336636613436363931303561303338373961306263643466653937626236
61336432306235663835666237323362333834306437396165373061346137343363346533653666
31633430626461623438333631663031343832666133366231633632343963333430376566653037
39393932626463663735333161353430383765363030663436633331373530636565663966666333
36376564376163653236643834313663366136343065616536636566393836646230363134393366
32383061346662393361646136383931653566663036366666323434613532616362316235656339
31353162313433656463383336613765313166663562646162336130393434663337653231636534
36613437363734613933336437303539376330363466616331303764613561316233383536636431
64643531313738306132623363333063623836623135376131396337346661613763386137356331
35643932643434643334363933623161666262653066376433663961653132356464373036643434
39626535383066626634363935303533616166363761376635396237356335636536393461646561
38346532383833326466626266313331386631656463616162653532623539303466646333393063
34376530363139373663323938393665633562653634613235393937326339313666393335343262
33373365366637616434313066333236396435646339646132393531393264343866383964396434
65306238373264323364366134373364343838666165633637643765326631386561356533336363
31333130653038316532643066383963343836383030336161306537646539393566343466613463
34346463646164323838323138663063653366386530613763363834303138646539313538323439
63613065323935363363386235353564623037316563303065366532316562373762356634383065
66663662346530643037333866393237663838336538323963633336653030343661393435656564
39393666663732366330386132633962333137363938646438386338666334633130366331643664
66306638333832306562343532313637666262333532303830353266326336643262346234376661
62306236363262373965613239323361656563363333626234313239316161656235353932373065
37636531623065373164613235333232303565303964663562633030643165353330376136343136
33303239363434346439386233613035626332343162393162373136646533643636336237303465
64353234323930653162333365393763623165636334343661356136376334383532393133393334
32383837376639393062613165616566306132333361616665333534386261653965353361323066
38383162313963343261333664396166306264313734333661633230383761393066343166666334
63353562306230633230316432626530666365316538383461663138653161346139626264306437
38343633393363333936373331346462663261636663343936653336613136336638333738613137
38646431306263313936623035616533366532376536646532626563303066616664626633636365
38623639333635663761376461613261393433323430653638626134363232343737376666383133
34313664633636626161626235323133376237353764383537353764656636633264646461376266
65356335376131663966623266353962373434633164386632663363333934383533613931316234
37663666326337626664356338366632646461316235366661346263386338373733613837363435
38383033306139353463333961363964393463343730303330306261636565643066383432653865
35346534326666386639633863393530333239363130343466376566313831356637383864343632
32343837386463636231656163356339346537623661623664626235313062356535646236353637
64636536323465383364313464343764393939323662383236613365653863353333623533623134
31396363646461626134356633643238323835336237313764313935633037366666333733353537
37323863396263303338323535313061663335646438643661323764653964383164303433626362
64336537363861323937366665363231306332616536623163376266306165633531376236626631
30303834666163666230636332353163383866313637356131373165306439363232616634366439
36663837333631626439393236393539616466643234376364636163643236323239623436313338
62366463363138623931343731656538613430313938623361653664616332363236386564356638
34316465313232373965663531363836626331346332376435346665346537326633353164663964
31343937303262356639666563316331636662333535356436353834383464343630656133306132
61363738386336356432323365363666333165396262616462613334623332666235643334333339
33366139653034663831656435613137626463653531343063656631316464313766616532656566
33653731376366626634303432633432363132626663666631356331336637313438363162396463
62666630663033363838373430336635356238313330663365333130643032353765613334323765
62626162663465313132623731323935306239363236653336623731313836356363393539373932
39396332393036623239316633386238646233633332383162633534346137303662363030303131
66336533326532383638326437313665356231346230303865366666623437356465653266353234
63626233373438653463306437636165636639323562363433643635633666383764303535653866
37383539363435373433383136633262396633613033303335386465326330306334653830663631
38633635343630326362336661303136663537616563616632396231326237373562346365393437
37313261363634653761646530396537356138376161353231303438633132623739353538343533
35373162326235306663303264663362643438366330616331316466363661646663366566316366
38373664306563616235303861343637663736316232396465396335343063643531666330636461
38323238356131343539353864373963626532356661636237353934613930363531643231653738
35383666666230356566666134323662303464313962613339666566646165663038653765346666
66306431366436666535333739396366643635336334643866356532353431623138623661303766
32626263633266336438373963306362653362616534353561363234643536326138363164633336
62333765623134363561326537353738653331643265323139373835326364613935373838363930
65303436353636623434393738643730393264386162346237663861333039373637393666666164
31373639326430316537303133346338623736656134326265633836663365613438613730363636
31363332313036343462366462363636323162303539353137643439643737626339336434633833
37363039353335386333653336343436336532323564373264383437343662366435643261376535
34323963333438383936326239646430353661326661333964623232363031303066343530346634
31323763356234616339316264376336626464616335616335313939396266626231366238666466
643935383963333031313166373762303137
---
- name: copy short cuts for ssh
copy:
name: 06-rpi.conf
dest: /etc/ssh/ssh_config.d/06-rpi.conf
- hosts: tgulab
vars:
- dhcpd:
domain: cn-tgu
subnet: 192.168.127.0
netmask: 255.255.255.0
range_start: 192.168.127.1
range_end: 192.168.127.100
routers: 192.168.127.10
broadcast: 192.168.127.255
host_list: host-list-cn-tgu
roles:
- dhcpd
- tgulab