1
1
mirror of https://github.com/OpenVoiceOS/OpenVoiceOS synced 2024-12-28 01:30:59 +01:00
OpenVoiceOS/buildroot-external/package/hostname-service/hostname.service

12 lines
288 B
Desktop File

[Unit]
Description=Set hostname to OpenVoiceOS-[MAC]
Before=NetworkManager.service
Before=avahi-daemon.service
[Service]
Type=oneshot
ExecStart=/bin/sh -c "hostnamectl set-hostname OpenVoiceOS-`sed 's/://g' /sys/class/net/eth0/address | tail -c 7`"
[Install]
WantedBy=multi-user.target