mirror of
https://github.com/OpenVoiceOS/OpenVoiceOS
synced 2025-04-15 19:07:24 +02:00
Re-Initiate the firstboot system utilizing a different approach
ovos-config as tool, starting of with expiring the default passwd
This commit is contained in:
parent
690de2d0fc
commit
8766df6b2b
@ -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
|
10
buildroot-external/rootfs-overlay/usr/sbin/ovos-config
Normal file
10
buildroot-external/rootfs-overlay/usr/sbin/ovos-config
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Check for first boot flag file
|
||||||
|
if [ -f "/etc/firstboot" ]; then
|
||||||
|
echo "[INFO] Expiring the mycroft user's password!"
|
||||||
|
passwd --expire mycroft
|
||||||
|
|
||||||
|
echo "[INFO] Removing firstboot flag!"
|
||||||
|
rm /etc/firstboot
|
||||||
|
fi
|
Loading…
x
Reference in New Issue
Block a user