Modernize repository: Fix shell scripts, update documentation, and improve configurability#1
Draft
Modernize repository: Fix shell scripts, update documentation, and improve configurability#1
Conversation
Co-authored-by: payrequestio <9915051+payrequestio@users.noreply.github.com>
Co-authored-by: payrequestio <9915051+payrequestio@users.noreply.github.com>
Co-authored-by: payrequestio <9915051+payrequestio@users.noreply.github.com>
Co-authored-by: payrequestio <9915051+payrequestio@users.noreply.github.com>
Co-authored-by: payrequestio <9915051+payrequestio@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Check for updates and improvements in the codebase
Modernize repository: Fix shell scripts, update documentation, and improve configurability
Oct 23, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
This PR modernizes the directadmin-restic-backup repository, which hadn't been updated in 2 years. The changes focus on code quality, configuration flexibility, documentation improvements, and repository hygiene while maintaining full backward compatibility.
Motivation
The repository had accumulated several technical debt issues:
Changes Made
Code Quality Improvements
All shell scripts have been modernized to follow current best practices:
$()command substitutionrestic_backup.shRESTICOUTPUT,RESTICSNAPSHOTS,total_space)Result: All 6 shell scripts now pass shellcheck without any errors or warnings.
Enhanced Configurability
Removed all hardcoded credentials and made them configurable through environment variables:
systemd-email-wrapper.shto properly handle environment variables in systemd servicesdirectadmin-cleaner.shoptional (checks if file exists before running)env.sh.templatewith all new optional configuration variablesDocumentation Overhaul
The README has been completely restructured with:
Repository Hygiene
b2_env.sh→env.sh)Testing
Impact
These changes make the backup solution:
Files Changed
All changes maintain full backward compatibility with existing installations.
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
https://api.github.com/repos/restic/restic/releases/latestcurl -s REDACTED(http block)If you need me to access, download, or install something from one of these locations, you can either:
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.