mirror of
https://github.com/OpenVoiceOS/OpenVoiceOS
synced 2025-06-05 22:19:21 +02:00
Splitting the build system for base and gui images
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
enable growdisk.service
|
||||
enable hostname.service
|
||||
enable sshd.service
|
||||
enable bluetooth.service
|
||||
enable avahi-daemon.service
|
||||
enable NetworkManager.service
|
||||
enable getty@tty1.service
|
||||
enable ovos-splash-start.service
|
||||
enable ovos-splash-systemd.service
|
||||
enable mycroft-admin-phal.service
|
||||
enable smb.service
|
||||
enable nmb.service
|
||||
enable mglru.service
|
||||
|
||||
disable pulseaudio.service
|
||||
disable getty@.service
|
||||
disable ovos-splash-quit.service
|
||||
disable mosquitto.service
|
||||
disable motion.service
|
||||
disable mpd.service
|
||||
disable shairport-sync.service
|
||||
disable snapclient.service
|
||||
disable snapserver.service
|
||||
disable spotifyd.service
|
||||
disable nodered.service
|
||||
disable btspeaker.service
|
||||
disable telnetd.service
|
||||
disable samba.service
|
||||
disable winbind.service
|
@@ -0,0 +1 @@
|
||||
#disable *
|
@@ -0,0 +1,18 @@
|
||||
#
|
||||
# Note that two different ALSA card state management schemes exist and they
|
||||
# can be switched using a file exist check - /etc/alsa/state-daemon.conf .
|
||||
#
|
||||
|
||||
[Unit]
|
||||
Description=Save/Restore Sound Card State
|
||||
ConditionPathExists=!/etc/alsa/state-daemon.conf
|
||||
ConditionPathExistsGlob=/dev/snd/control*
|
||||
ConditionPathExists=/etc/voicecard/asound.state
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
RemainAfterExit=true
|
||||
ExecStartPre=/bin/mkdir -p /run/alsa
|
||||
ExecStart=-/usr/sbin/alsactl -E HOME=/run/alsa -f /etc/voicecard/asound.state restore
|
||||
ExecStop=-/usr/sbin/alsactl -E HOME=/run/alsa -f /etc/voicecard/asound.state store
|
||||
|
@@ -0,0 +1,5 @@
|
||||
[Unit]
|
||||
Description=D-Bus System Message Bus Socket
|
||||
|
||||
[Socket]
|
||||
ListenStream=/run/dbus/system_bus_socket
|
@@ -0,0 +1,10 @@
|
||||
[Unit]
|
||||
Description=OVOS ZRAM swap
|
||||
Requires=zram-swap.service
|
||||
After=zram-swap.service
|
||||
|
||||
[Swap]
|
||||
What=/dev/zram0
|
||||
|
||||
[Install]
|
||||
WantedBy=swap.target
|
@@ -0,0 +1,11 @@
|
||||
[Unit]
|
||||
Description=Configure multigenerational LRU
|
||||
ConditionPathExists=/sys/kernel/mm/lru_gen/enabled
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
|
||||
ExecStart=/bin/sh -c "echo 1 > /sys/kernel/mm/lru_gen/min_ttl_ms"
|
||||
|
||||
[Install]
|
||||
WantedBy=basic.target
|
@@ -0,0 +1,16 @@
|
||||
[Unit]
|
||||
Description=Admin PHAL
|
||||
|
||||
[Service]
|
||||
#Type=notify
|
||||
ExecStart=/usr/libexec/mycroft-systemd-admin-phal
|
||||
#TimeoutStartSec=1m
|
||||
#TimeoutStopSec=1m
|
||||
Restart=on-failure
|
||||
#StartLimitInterval=5min
|
||||
#StartLimitBurst=4
|
||||
#StartLimitAction=reboot-force
|
||||
#WatchdogSec=30s
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
@@ -0,0 +1,16 @@
|
||||
[Unit]
|
||||
Description=OVOS First boot run script
|
||||
DefaultDependencies=no
|
||||
Conflicts=shutdown.target
|
||||
After=systemd-remount-fs.service
|
||||
Before=sysinit.target shutdown.target
|
||||
ConditionPathIsReadWrite=/etc
|
||||
ConditionPathExists=/etc/firstboot
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
RemainAfterExit=yes
|
||||
ExecStart=/usr/sbin/ovos-config
|
||||
|
||||
[Install]
|
||||
WantedBy=sysinit.target
|
@@ -0,0 +1,6 @@
|
||||
[Unit]
|
||||
Description=OVOS zram targets
|
||||
Documentation=man:systemd.target(5)
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
@@ -0,0 +1,8 @@
|
||||
[Unit]
|
||||
Description=OpenVoiceOS - Mycroft GUI Interface
|
||||
Documentation=man:systemd.special(7)
|
||||
Requires=multi-user.target
|
||||
Wants=mycroft-gui.service
|
||||
Conflicts=rescue.service rescue.target
|
||||
After=multi-user.target rescue.service rescue.target
|
||||
AllowIsolate=yes
|
@@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=PulseAudio Sound System
|
||||
After=syslog.target
|
||||
After=avahi-daemon.service network.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/pulseaudio --system --daemonize=no
|
||||
Restart=always
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
@@ -0,0 +1,8 @@
|
||||
[Unit]
|
||||
Description=RPCbind Server Activation Socket
|
||||
|
||||
[Socket]
|
||||
ListenStream=/run/rpcbind.sock
|
||||
|
||||
[Install]
|
||||
WantedBy=sockets.target
|
@@ -0,0 +1,21 @@
|
||||
[Unit]
|
||||
Description=Shairport-sync
|
||||
Wants=sound.target
|
||||
After=sound.target
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
After=pulseaudio.service
|
||||
Requires=avahi-daemon.service
|
||||
After=avahi-daemon.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=mycroft
|
||||
# Avahi daemon needs some time until fully ready
|
||||
ExecStartPre=/bin/sleep 3
|
||||
ExecStart=/usr/bin/shairport-sync
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
@@ -0,0 +1,15 @@
|
||||
[Unit]
|
||||
Description=OVOS ZRAM swap
|
||||
DefaultDependencies=no
|
||||
Before=dev-zram0.swap
|
||||
RefuseManualStart=true
|
||||
RefuseManualStop=true
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/libexec/ovos-zram -t swap
|
||||
RemainAfterExit=true
|
||||
StandardOutput=null
|
||||
|
||||
[Install]
|
||||
WantedBy=ovos-zram.target
|
@@ -0,0 +1,17 @@
|
||||
enable pulseaudio.service
|
||||
enable pulseaudio.socket
|
||||
|
||||
enable mycroft.service
|
||||
enable mycroft-messagebus.service
|
||||
enable mycroft-voice.service
|
||||
enable mycroft-audio.service
|
||||
enable mycroft-skills.service
|
||||
enable mycroft-gui.service
|
||||
enable mycroft-enclosure-gui.service
|
||||
enable mycroft-phal.service
|
||||
|
||||
disable local-backend.service
|
||||
|
||||
enable kdeconnectd.service
|
||||
enable shairport-sync.service
|
||||
enable spotifyd.service
|
@@ -0,0 +1 @@
|
||||
enable dbus.socket
|
@@ -0,0 +1,10 @@
|
||||
[Unit]
|
||||
Description=D-Bus User Message Bus
|
||||
Requires=dbus.socket
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/dbus-daemon --session --address=systemd: --nofork --nopidfile --systemd-activation
|
||||
ExecReload=/usr/bin/dbus-send --print-reply --session --type=method_call --dest=org.freedesktop.DBus / org.freedesktop.DBus.ReloadConfig
|
||||
|
||||
[Install]
|
||||
Also=dbus.socket
|
@@ -0,0 +1,10 @@
|
||||
[Unit]
|
||||
Description=D-Bus User Message Bus Socket
|
||||
|
||||
[Socket]
|
||||
ListenStream=%t/bus
|
||||
ExecStartPost=-/bin/systemctl --user set-environment DBUS_SESSION_BUS_ADDRESS=unix:path=%t/bus
|
||||
|
||||
[Install]
|
||||
WantedBy=sockets.target
|
||||
Also=dbus.service
|
@@ -0,0 +1,14 @@
|
||||
[Unit]
|
||||
Description=Connect your OVOS-Device to your smartphone or tablet
|
||||
Wants=sound.target
|
||||
After=sound.target
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
After=pulseaudio.service
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/lib/libexec/kdeconnectd -platform offscreen
|
||||
BusName=org.kde.kdeconnect
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
@@ -0,0 +1,20 @@
|
||||
[Unit]
|
||||
Description=Mycroft Skills
|
||||
PartOf=mycroft.service
|
||||
After=mycroft.service
|
||||
After=mycroft-messagebus.service
|
||||
|
||||
[Service]
|
||||
ExecStart=ovos-local-backend
|
||||
StandardOutput=append:/home/mycroft/.local/state/mycroft/local-backend.log
|
||||
#StandardError=file:/home/mycroft/.local/state/mycroft/local-backend.error.log
|
||||
TimeoutStartSec=10m
|
||||
TimeoutStopSec=1m
|
||||
Restart=on-failure
|
||||
StartLimitInterval=5min
|
||||
StartLimitBurst=4
|
||||
#StartLimitAction=reboot-force
|
||||
#WatchdogSec=30s
|
||||
|
||||
[Install]
|
||||
WantedBy=mycroft.service
|
@@ -0,0 +1,23 @@
|
||||
[Unit]
|
||||
Description=Mycroft Audio
|
||||
PartOf=mycroft.service
|
||||
After=mycroft.service
|
||||
After=mycroft-messagebus.service
|
||||
After=pulseaudio.service
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
ExecStart=/usr/libexec/mycroft-systemd-audio
|
||||
StandardOutput=append:/var/log/mycroft/audio.log
|
||||
StandardError=append:/var/log/mycroft/audio.error.log
|
||||
TimeoutStartSec=1m
|
||||
TimeoutStopSec=1m
|
||||
Restart=on-failure
|
||||
StartLimitInterval=5min
|
||||
StartLimitBurst=4
|
||||
#StartLimitAction=reboot-force
|
||||
#WatchdogSec=30s
|
||||
|
||||
[Install]
|
||||
WantedBy=mycroft.service
|
||||
|
@@ -0,0 +1,20 @@
|
||||
[Unit]
|
||||
Description=Mycroft Messagebus
|
||||
PartOf=mycroft.service
|
||||
After=mycroft.service
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
ExecStart=/usr/libexec/mycroft-systemd-messagebus
|
||||
StandardOutput=append:/var/log/mycroft/messagebus.log
|
||||
StandardError=append:/var/log/mycroft/messagebus.error.log
|
||||
TimeoutStartSec=1m
|
||||
TimeoutStopSec=1m
|
||||
Restart=on-failure
|
||||
StartLimitInterval=5min
|
||||
StartLimitBurst=4
|
||||
#StartLimitAction=reboot-force
|
||||
#WatchdogSec=30s
|
||||
|
||||
[Install]
|
||||
WantedBy=mycroft.service
|
@@ -0,0 +1,22 @@
|
||||
[Unit]
|
||||
Description=Mycroft PHAL
|
||||
PartOf=mycroft.service
|
||||
After=mycroft.service
|
||||
After=mycroft-messagebus.service
|
||||
After=pulseaudio.service
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
ExecStart=/usr/libexec/mycroft-systemd-phal
|
||||
StandardOutput=append:/var/log/mycroft/phal.log
|
||||
StandardError=append:/var/log/mycroft/phal.error.log
|
||||
TimeoutStartSec=1m
|
||||
TimeoutStopSec=1m
|
||||
Restart=on-failure
|
||||
StartLimitInterval=5min
|
||||
StartLimitBurst=4
|
||||
#StartLimitAction=reboot-force
|
||||
#WatchdogSec=30s
|
||||
|
||||
[Install]
|
||||
WantedBy=mycroft.service
|
@@ -0,0 +1,22 @@
|
||||
[Unit]
|
||||
Description=Mycroft Skills
|
||||
PartOf=mycroft.service
|
||||
After=mycroft.service
|
||||
After=mycroft-messagebus.service
|
||||
After=pulseaudio.service
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
ExecStart=/usr/libexec/mycroft-systemd-skills
|
||||
StandardOutput=append:/var/log/mycroft/skills.log
|
||||
StandardError=append:/var/log/mycroft/skills.error.log
|
||||
TimeoutStartSec=10m
|
||||
TimeoutStopSec=1m
|
||||
Restart=on-failure
|
||||
StartLimitInterval=5min
|
||||
StartLimitBurst=4
|
||||
#StartLimitAction=reboot-force
|
||||
#WatchdogSec=30s
|
||||
|
||||
[Install]
|
||||
WantedBy=mycroft.service
|
@@ -0,0 +1,23 @@
|
||||
[Unit]
|
||||
Description=Mycroft Voice
|
||||
PartOf=mycroft.service
|
||||
After=mycroft.service
|
||||
After=mycroft-messagebus.service
|
||||
After=pulseaudio.service
|
||||
|
||||
[Service]
|
||||
Type=notify
|
||||
ExecStart=/usr/libexec/mycroft-systemd-voice
|
||||
StandardOutput=append:/var/log/mycroft/voice.log
|
||||
StandardError=append:/var/log/mycroft/voice.error.log
|
||||
TimeoutStartSec=1m
|
||||
TimeoutStopSec=1m
|
||||
Restart=on-failure
|
||||
Restart=on-failure
|
||||
StartLimitInterval=5min
|
||||
StartLimitBurst=4
|
||||
#StartLimitAction=reboot-force
|
||||
#WatchdogSec=30s
|
||||
|
||||
[Install]
|
||||
WantedBy=mycroft.service
|
@@ -0,0 +1,10 @@
|
||||
[Unit]
|
||||
Description=Mycroft A.I. Software stack.
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/bin/true
|
||||
RemainAfterExit=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
@@ -0,0 +1,35 @@
|
||||
[Unit]
|
||||
Description=Sound Service
|
||||
|
||||
# We require pulseaudio.socket to be active before starting the daemon, because
|
||||
# while it is possible to use the service without the socket, it is not clear
|
||||
# why it would be desirable.
|
||||
#
|
||||
# A user installing pulseaudio and doing `systemctl --user start pulseaudio`
|
||||
# will not get the socket started, which might be confusing and problematic if
|
||||
# the server is to be restarted later on, as the client autospawn feature
|
||||
# might kick in. Also, a start of the socket unit will fail, adding to the
|
||||
# confusion.
|
||||
#
|
||||
# After=pulseaudio.socket is not needed, as it is already implicit in the
|
||||
# socket-service relationship, see systemd.socket(5).
|
||||
Requires=pulseaudio.socket
|
||||
ConditionUser=!root
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/pulseaudio --daemonize=no --log-target=journal
|
||||
LockPersonality=yes
|
||||
MemoryDenyWriteExecute=yes
|
||||
NoNewPrivileges=yes
|
||||
RestartSec=5
|
||||
Restart=on-failure
|
||||
RestrictNamespaces=yes
|
||||
SystemCallArchitectures=native
|
||||
SystemCallFilter=@system-service
|
||||
# Note that notify will only work if --daemonize=no
|
||||
Type=notify
|
||||
UMask=0077
|
||||
|
||||
[Install]
|
||||
Also=pulseaudio.socket
|
||||
WantedBy=default.target
|
@@ -0,0 +1,15 @@
|
||||
[Unit]
|
||||
Description=Shairport-sync
|
||||
After=sound.target
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
After=pulseaudio.service
|
||||
After=avahi-daemon.service
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/shairport-sync -c %h/.config/shairport-sync/shairport-sync.conf
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
@@ -0,0 +1,16 @@
|
||||
[Unit]
|
||||
Description=A Spotify connect daemon
|
||||
Documentation=https://github.com/Spotifyd/spotifyd
|
||||
Wants=sound.target
|
||||
After=sound.target
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
After=pulseaudio.service
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/spotifyd --no-daemon
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
Reference in New Issue
Block a user