mirror of https://dev.ccchb.de/ccchb/ansible.git
parent
b7db27558b
commit
050fb34846
|
@ -11,13 +11,13 @@
|
||||||
group: wheel
|
group: wheel
|
||||||
mode: 0755
|
mode: 0755
|
||||||
with_items:
|
with_items:
|
||||||
- /etc/s6-rc
|
- '{{ s6_etc_dir }}'
|
||||||
- /etc/s6-rc/service
|
- '{{ s6_etc_dir }}/service'
|
||||||
- /etc/s6-rc/service/enabled
|
- '{{ s6_etc_dir }}/service/enabled'
|
||||||
|
|
||||||
- name: Define enabled services bundle
|
- name: Define enabled services bundle
|
||||||
copy:
|
copy:
|
||||||
dest: /etc/s6-rc/service/enabled/type
|
dest: '{{ s6_etc_dir }}/service/enabled/type'
|
||||||
content: bundle
|
content: bundle
|
||||||
owner: root
|
owner: root
|
||||||
group: wheel
|
group: wheel
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
- name: Default to an empty set of enabled servics
|
- name: Default to an empty set of enabled servics
|
||||||
file:
|
file:
|
||||||
path: /etc/s6-rc/service/enabled/contents
|
path: '{{ s6_etc_dir }}/service/enabled/contents'
|
||||||
state: touch
|
state: touch
|
||||||
owner: root
|
owner: root
|
||||||
group: wheel
|
group: wheel
|
||||||
|
@ -46,15 +46,15 @@
|
||||||
command: >
|
command: >
|
||||||
s6-rc-compile -v 2 .compiled.{{ s6_uuid }} service
|
s6-rc-compile -v 2 .compiled.{{ s6_uuid }} service
|
||||||
args:
|
args:
|
||||||
creates: /etc/s6-rc/compiled
|
creates: '{{ s6_etc_dir }}/compiled'
|
||||||
chdir: /etc/s6-rc
|
chdir: '{{ s6_etc_dir }}'
|
||||||
|
|
||||||
- name: Link to the latest service database
|
- name: Link to the latest service database
|
||||||
command: >
|
command: >
|
||||||
env ln -shf .compiled.{{ s6_uuid }} compiled
|
env ln -shf .compiled.{{ s6_uuid }} compiled
|
||||||
args:
|
args:
|
||||||
creates: /etc/s6-rc/compiled
|
creates: '{{ s6_etc_dir }}/compiled'
|
||||||
chdir: /etc/s6-rc
|
chdir: '{{ s6_etc_dir }}'
|
||||||
|
|
||||||
- name: Make sure that tmpfs support is loaded early
|
- name: Make sure that tmpfs support is loaded early
|
||||||
lineinfile:
|
lineinfile:
|
||||||
|
@ -72,7 +72,7 @@
|
||||||
|
|
||||||
- name: Generate s6-svscan startup script
|
- name: Generate s6-svscan startup script
|
||||||
template:
|
template:
|
||||||
dest: /etc/s6-rc/scan
|
dest: '{{ s6_etc_dir }}/scan'
|
||||||
src: scan.j2
|
src: scan.j2
|
||||||
owner: root
|
owner: root
|
||||||
group: wheel
|
group: wheel
|
||||||
|
@ -82,7 +82,7 @@
|
||||||
lineinfile:
|
lineinfile:
|
||||||
path: /etc/ttys
|
path: /etc/ttys
|
||||||
regexp: '^null'
|
regexp: '^null'
|
||||||
line: 'null "/etc/s6-rc/scan" vt100 on secure'
|
line: 'null "{{ s6_etc_dir }}/scan" vt100 on secure'
|
||||||
notify:
|
notify:
|
||||||
- Reload /etc/ttys
|
- Reload /etc/ttys
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
#!/bin/sh -e
|
#!/bin/sh -e
|
||||||
|
|
||||||
export PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/root/bin
|
export PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/root/bin
|
||||||
|
scan_dir="{{ s6_scan_dir }}"
|
||||||
|
|
||||||
install -d -o root -g wheel -m 755 /run/service
|
install -d -o root -g wheel -m 755 -- "$scan_dir"
|
||||||
exec s6-svscan /run/service
|
exec s6-svscan "$scan_dir"
|
||||||
|
|
Loading…
Reference in New Issue