almost working

This commit is contained in:
2019-10-04 06:41:13 -07:00
parent bad920ab58
commit 0c72b2c372
7 changed files with 48 additions and 38 deletions

View File

@@ -1,24 +0,0 @@
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
# Print the IP address
_IP=$(hostname -I) || true
if [ "$_IP" ]; then
printf "My IP address is %s\n" "$_IP"
fi
if [ -e /boot/rc.local.txt ]; then
. /boot/rc.local.txt
fi
exit 0

View File

@@ -1,5 +0,0 @@
#!/bin/bash
whoami
uptime
cat /etc/rc.local

View File

@@ -1,7 +1,8 @@
[Unit]
Description=Run user provided scripts on boot
ConditionPathExists=/usr/lib/raspi-ini/run-parts.sh
After=dhcpcd.service # Need to put more thought into when
After=network-online.target
Wants=network-online.target
[Service]
Type=oneshot

View File

@@ -4,7 +4,7 @@
shopt -s nullglob
# Run every per-once script
run-parts --regex '.*\.sh$' /boot/per-once.d
run-parts --regex '.*\.sh$' /boot/per-once.d |
# Rename every per-once script
for f in /boot/per-once.d/*.sh; do