Skip to content

Commit

Permalink
Merges branch 'init-cleanup'.
Browse files Browse the repository at this point in the history
This is posted as, and therefore merges ninjablocks#12.
  • Loading branch information
hlapp committed Feb 14, 2016
2 parents 619a606 + 5da4e05 commit cf4c221
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions init/ninjablock.conf
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@ pre-start script

# setup serial port for BBW
if [ "$NINJA_HARDWARE_TYPE" == "BBW" ]; then
sudo $bin_dir/setserial
$bin_dir/setserial
fi

# configure gpio pins
sudo $bin_dir/setgpio
$bin_dir/setgpio

if [ ! -f /etc/opt/ninja/.has_updated_system ]; then
$bin_dir/ninja_update_system
Expand All @@ -56,12 +56,12 @@ pre-start script
if [ ! -f /etc/opt/ninja/.has_updated_utilities ]; then
$bin_dir/ninja_update_utilities
fi
sudo echo "ubuntu ALL=NOPASSWD: /sbin/ifconfig, /sbin/iwlist" > /etc/sudoers.d/ninja
sudo chmod 0440 /etc/sudoers.d/ninja
sudo chown -R ubuntu:ubuntu /opt/ninja
sudo chown ubuntu:ubuntu /opt/utilities/tmp
sudo chown ubuntu:ubuntu /var/log/ninjablock.log
sudo chown ubuntu:ubuntu /etc/opt/ninja
echo "ubuntu ALL=NOPASSWD: /sbin/ifconfig, /sbin/iwlist" > /etc/sudoers.d/ninja
chmod 0440 /etc/sudoers.d/ninja
chown -R ubuntu:ubuntu /opt/ninja
chown ubuntu:ubuntu /opt/utilities/tmp
chown ubuntu:ubuntu /var/log/ninjablock.log
chown ubuntu:ubuntu /etc/opt/ninja
tail -n 1000 /var/log/ninjablock.log > /opt/utilities/tmp/new.log
cat /opt/utilities/tmp/new.log>/var/log/ninjablock.log
rm /opt/utilities/tmp/new.log
Expand Down
Empty file removed init/setgpio.conf
Empty file.
Empty file removed init/setserial.conf
Empty file.

0 comments on commit cf4c221

Please sign in to comment.