HeavyScript installation and setup for TrueNAS management.
TrueNAS Scale setup completed.
Logged in as administrative user.
HeavyScript is a bash tool for automating TrueNAS Scale application management. It is recommended in the TrueCharts documentation, but is not required when using TrueCharts. Refer to the HeavyScript GitHub repository for more information.
HeavyScript is not a TrueNAS or TrueCharts application, it must be installed from terminal. Open a shell session on your server:
System Settings -
curl -s https://raw.githubusercontent.com/Heavybullets8/heavy_script/main/functions/deploy.sh | bash && source "$HOME/.bashrc" 2>/dev/null && source "$HOME/.zshrc" 2>/dev/null
Schedule HeavyScript to run with a cron job.
HeavyScript command to update system applications. Can be configured with multiple flags, refer to the project repository for a full flag list.
Basic update command, use this when configuring with a
bash /root/heavy_script/heavy_script.sh update
Update command with flags, set to ignore
bash /root/heavy_script/heavy_script.sh update --backup 14 --concurrent 5 --no-config --prune --rollback --sync --self-update
|Create backup and keep specified number of backups.
|How many applications to update at once.
|Remove unused images after updates.
config.ini file. This will use defaults unless a value is specified with a flag. Remove this to use
config.ini for configuration.
|Rollback to previous version if update fails.
Schedule a cron job on the TrueNAS system in advanced settings. Navigate to
System Settings -
Advanced and locate the
Cron Jobs section.
Add to add a new cron job, read the warning provided by TrueNAS. Configure it as detailed, modify the command as necessary for the system.
|Cron job description when viewing in the administrative interface.
|HeavyScript command to execute when scheduled. Modify to flags as required.
|Run As User
|User to execute the cron job as. HeavyScript requires being the root user to function.
(0 5 * * *)
|When to run the cron job. This value will run the the job at 5:00 AM every day.
|Hide Standard Output
|When false, standard output will be sent to the executing user.
|Hide Standard Error
|When false, error output will be sent to the executing user.
|Run state of the cron job.
Save the cron job and optionally
Run Now to verify it works as intended.
The configuration file is created when the script is first executed. Run the script once before attempting to modify its settings.
When using the
config.ini for configuring HeavyScript, remove the
--no-config flag from the cron job command.