Skip to content

Commit

Permalink
v6.29 (#3402)
Browse files Browse the repository at this point in the history
+ DietPi-RAMdisk | Replace with vmtouch to use native file system caching instead of tmpfs for DietPi scripts and config files. /DietPi is symlinked to /boot on update for backwards-compatibility, but on new images /boot/dietpi path must be used from now on.
+ Network | Disable power management for network devices only, assure via SUBSYSTEM. Run it on actual added WiFi adapter instead of fixed wlan0 via "%k", which matches KERNEL name.
+ DietPi-Run_NTPD | Do not create .ntpd_override flag file. We never handle/use this currently. Re-add when we implement some special override handling.
+ DietPi-Launcher | Prompt for user action if any program exits with exit code, so error messages can be reviewed
+ DietPi-Patch | Schedule DietPi-Update restart, required for all pre-v6.29 systems due to DietPi-RAMdisk removal
+ DietPi-Patch | Failsafe: Migrate Fourdee => MichaIng Git owner on every patch, if found, so it will be effective after first update. Else DietPi-Update will override ".version" entry after incremental patches and new owner becomes effective only after another DietPi-Update.
+ DietPi-Software | RPi Cam Control: Align service script syntax with our other bash scripts, remove non-Debian (Ubuntu?) compatibility and remove 4 seconds sleep before calling "raspimjpeg" (It makes sense to wait for it being fully initialised before calling the PHP schedule script, but no point in waiting before calling the very first daemon.)
+ DietPi-Set_software | Verify_DietPi_Txt: Pre-v6.29 workaround
+ DietPi-Set_software | Verify_DietPi_Txt: Pull new dietpi.txt from repo of chosen Git owner instead of fixed "MichaIng"
+ DietPi-Set_software | Verify_DietPi_Txt: Remove really all empty and commented lines from dietpi.txt before scraping it, including those with leading white space characters. Scrape lines in raw format to avoid having backslashes interpreted as escape character.
+ System | Add DietPi runtime dir for temporary cross-script flag and info files
+ DietPi-Update | Use new /run/dietpi runtime dir for update available flag
+ DietPi-Update | Download tarball update archive: less traffic, faster extraction
+ DietPi-Update | Use curl instead of wget, which executes faster, and since we might to drop wget dependency completely. It can be used in combination with G_RUN_CMD when using "-o" option instead of ">" STDOUT redirect
+ DietPi-Update | Minor coding
+ DietPi-Cloudshell | Minor coding, especially do not unset local arrays/variables before the function ends and do not unset anything before exiting the script, since both has no practical effect
+ DietPi-Run_NTPD | Use new /run/dietpi runtime dir to log exit status
+ DietPi-Obtain_network_details | Use new /run/dietpi runtime dir to store network info. This is created at boot, hence we can set permissions once there
+ DietPi-WiFi-Monitor | Remove doubled obtain_network_details call + adapter check, which is already done as PreStartExec in the systems unit, which allows to see the service failing on console when calling "systemctl (re)start dietpi-wifi-monitor". Adapter is checked again when ping fails to exit when adapter has been unplugged, got power loss or similar.
+ DietPi-WiFi-Monitor | Do not try to ping if no default gateway is assigned, assume lost connection then as well. NB: We currently do not allow WiFi monitor on interfaces with no default gateway assigned (local network only, WiFi direct or where this might be possible?), since we cannot know any local IP to ping then.
+ DietPi-Boot | Do not manually ifup network interfaces anymore. The udev rules that start [email protected] should work reliable for hotplug interfaces. We anyway wait, hence we can include waiting until the network interfaces have been brought up by native ifupdown services. Another reason is that the current method might bring up the wrong interfaces, since .network might not even exit or from last shutdown might not contain the interfaces that are configured in /etc/network/interfaces. The latter is what we should scrape in this case we want or need to re-implement it. Last but not least, .network is not boot-persistent anymore 😉.
+ DietPi-Boot | There is no point in running run_ntpd as background service, since it is the last command and systemd does not allow any follow-up service to start before as well every background process has finished.
+ DietPi-Banner | Do not call obtain_network_details, which is done within DietPi-Boot and DietPi-Login already. If user does not actively delete the file, it must be present. This also allows to skip making it world-writeable.
+ DietPi-Bugreport | Include new runtime dir into upload archive
+ DietPi-Bugreport | Fix boot/kernel config file names
+ DietPi-Bugreport | Add APT preferences files and simplify *.d/ drop-in config inclusions
+ DietPi-NordVPN | Wait for network-online.target, which is now available on all supported distro versions
+ DietPi-Globals | Check if G_PROGRAM_NAME has a non-empty string assigned, instead of checking if it is declared only, before using it in titles etc.
+ DietPi-Globals | Move G_FP_LOG_APT to /tmp tmpfs, since it is removed by G_ERROR_HANDLER in every case anyway, after in case printing error log to console. More persistent log can be as well found in /etc/apt/ and /etc/dpkg.log.
+ DietPi-Software | HAProxy: Update sysvinit service to comply with current DietPi and Debian versions and our current code standards. ToDo: There is a systemd unit included with the package, hence is our sysvinit service even in use?
+ DietPi-PREP | Download DietPi archive as tarball
+ DietPi-Patch | Add an info before terminating obsolete DietPi-Update parent instance, else the "Terminated" print might users feel rattled: #3402 (comment)
  • Loading branch information
MichaIng authored Mar 7, 2020
1 parent a32dc3b commit 727a5a7
Show file tree
Hide file tree
Showing 86 changed files with 1,896 additions and 2,192 deletions.
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-backup.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Backup
Type=Application
Comment=Backup and Restore your DietPi System.
Terminal=true
Exec=/DietPi/dietpi/dietpi-backup
Exec=/boot/dietpi/dietpi-backup
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Backup
GenericName=DietPi-Backup
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-bugreport.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-BugReport
Type=Application
Comment=Found an issue or bug? Let us know!
Terminal=true
Exec=/DietPi/dietpi/dietpi-bugreport
Exec=/boot/dietpi/dietpi-bugreport
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-BugReport
GenericName=DietPi-BugReport
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-cleaner.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Cleaner
Type=Application
Comment=Removes unwanted junk from your system.
Terminal=true
Exec=/DietPi/dietpi/dietpi-cleaner
Exec=/boot/dietpi/dietpi-cleaner
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Cleaner
GenericName=DietPi-Cleaner
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-config.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Config
Type=Application
Comment=Feature rich config tool for DietPi
Terminal=true
Exec=/DietPi/dietpi/dietpi-config
Exec=/boot/dietpi/dietpi-config
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Config
GenericName=DietPi-Config
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-cron.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Cron
Type=Application
Comment=Menu system that allows you to modify cron job start times.
Terminal=true
Exec=/DietPi/dietpi/dietpi-cron
Exec=/boot/dietpi/dietpi-cron
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Cron
GenericName=DietPi-Cron
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-drive_manager.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Drive Manager
Type=Application
Comment=Mount local and network drives
Terminal=true
Exec=/DietPi/dietpi/dietpi-drive_manager
Exec=/boot/dietpi/dietpi-drive_manager
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Drive_Manager
GenericName=DietPi-Drive_Manager
2 changes: 1 addition & 1 deletion .conf/desktop/apps/dietpi-justboom.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-JustBoom
Type=Application
Comment=Tweak audio options for your JustBoom (and others) soundcard
Terminal=true
Exec=/DietPi/dietpi/misc/dietpi-justboom
Exec=/boot/dietpi/misc/dietpi-justboom
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/justboom.png
Categories=ConsoleOnly;System;AudioVideo;
GenericName=DietPi-JustBoom
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-launcher.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Launcher
Type=Application
Comment=Menu system that allows you to run any of the DietPi programs.
Terminal=true
Exec=/DietPi/dietpi/dietpi-launcher
Exec=/boot/dietpi/dietpi-launcher
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Launcher
GenericName=DietPi-Launcher
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-services.desktop
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[Desktop Entry]
Version=2.0
Version=1.0
Name=DietPi-Services
Type=Application
Comment=Control system services and apply process tool tweaks
Terminal=true
Exec=/DietPi/dietpi/dietpi-services
Exec=/boot/dietpi/dietpi-services
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Services
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-software.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Software
Type=Application
Comment=Quickly and easily install DietPi optimized software.
Terminal=true
Exec=/DietPi/dietpi/dietpi-software
Exec=/boot/dietpi/dietpi-software
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Software
GenericName=DietPi-Software
6 changes: 3 additions & 3 deletions .conf/desktop/apps/dietpi-sync.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Sync
Type=Application
Comment=Duplicate (Sync) one location to another
Terminal=true
Exec=/DietPi/dietpi/dietpi-sync
Exec=/boot/dietpi/dietpi-sync
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Sync
Categories=ConsoleOnly;Utility;Archiving;
GenericName=DietPi-Sync
4 changes: 2 additions & 2 deletions .conf/desktop/apps/dietpi-update.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Name=DietPi-Update
Type=Application
Comment=Update your version of DietPi
Terminal=true
Exec=/DietPi/dietpi/dietpi-update
Exec=/boot/dietpi/dietpi-update
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/dietpi-icon.png
Categories=ConsoleOnly;System;
GenericName=DietPi-Update
GenericName=DietPi-Update
4 changes: 2 additions & 2 deletions .conf/desktop/apps/kodi.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ Version=1.0
Name=Kodi Media Center
GenericName=Media Center
Comment=Manage and view your media
Exec=/DietPi/dietpi/misc/start_kodi
Exec=/boot/dietpi/misc/start_kodi
Icon=/var/lib/dietpi/dietpi-software/installed/desktop/icons/kodi-icon.png
Terminal=false
Type=Application
Categories=AudioVideo;Video;Player;TV;
Categories=AudioVideo;Video;Player;TV;
32 changes: 9 additions & 23 deletions .conf/dps_59/raspimjpeg.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,15 @@
# Created by Daniel Knight / [email protected] / dietpi.com
#
# Info:
# - Location /var/lib/dietpi/dietpi-software/services/raspimjpeg.service
# - Allows service control for Raspimjpeg and PHP schedule, used by RPI Camera Web
# - Called from /DietPi/dietpi/dietpi-services
# - Location: /var/lib/dietpi/dietpi-software/services/raspimjpeg.sh
# - Allows service control for Raspimjpeg and PHP schedule, used by RPi Camera Web
# - Called from /etc/systemd/system/raspimjpeg.service
#
#////////////////////////////////////

Raspimjeg_Stop(){

killall -w raspimjpeg &> /dev/null
killall -w php &> /dev/null
killall -w raspimjpeg php &> /dev/null

}

Expand All @@ -25,34 +24,21 @@
mkdir -p /dev/shm/mjpeg
chown www-data:www-data /dev/shm/mjpeg
chmod 777 /dev/shm/mjpeg
sudo -u www-data raspimjpeg &> /dev/null &
sleep 4
sudo -u www-data raspimjpeg > /dev/null 2>&1 &
if [ -e /etc/debian_version ]; then

sleep 4
sudo -u www-data php /var/www/rpicam/schedule.php > /dev/null 2>&1 &

else

sleep 4
sudo -u www-data /bin/bash -c php /var/www/rpicam/schedule.php > /dev/null 2>&1 &

fi
sudo -u www-data php /var/www/rpicam/schedule.php &> /dev/null &

}

if [ "$1" = "stop" ]; then
if [[ $1 == 'stop' ]]; then

Raspimjeg_Stop

fi

if [ "$1" = "start" ]; then
elif [[ $1 == 'start' ]]; then

Raspimjeg_Start

fi

exit 0

}
}
Loading

0 comments on commit 727a5a7

Please sign in to comment.