Add stage3

- Install libnss-mdns package
- Sudo without password
- Add and enable vision service
This commit is contained in:
Nathan Mutin
2019-07-29 17:55:54 +02:00
parent 7870976ae7
commit d8787ee10e
6 changed files with 34 additions and 1 deletions
+1
View File
@@ -0,0 +1 @@
libnss-mdns
+4
View File
@@ -0,0 +1,4 @@
#!/bin/bash -e
# Enable password-less sudo for everyone
echo "%sudo ALL=(ALL) NOPASSWD:ALL" >> "${ROOTFS_DIR}/etc/sudoers"
+12
View File
@@ -0,0 +1,12 @@
#!/bin/bash -e
# Install the service so the system can run it
install -m 755 files/vision.service "${ROOTFS_DIR}/etc/systemd/system"
on_chroot << EOF
# Reload the system services
sudo systemctl daemon-reload
# Enable our vision service on startup
sudo systemctl enable vision
EOF
@@ -0,0 +1,11 @@
[Unit]
Description=FRC Vision Service
[Service]
Type=simple
Restart=always
ExecStart=/home/vision/visionProgram
WorkingDirectory=/home/vision
[Install]
WantedBy=multi-user.target
+5
View File
@@ -0,0 +1,5 @@
#!/bin/bash -e
if [ ! -d "${ROOTFS_DIR}" ]; then
copy_previous
fi