diff --git a/plogical/Backupsv2.py b/plogical/Backupsv2.py index 8f7d848ae..4ea24277d 100644 --- a/plogical/Backupsv2.py +++ b/plogical/Backupsv2.py @@ -1262,13 +1262,25 @@ def InstallRustic(self): return 0, str(response.content) # sudo mv filename /usr/bin/ - command = 'wget -P /home/rustic https://github.com/rustic-rs/rustic/releases/download/%s/rustic-%s-x86_64-unknown-linux-musl.tar.gz' % ( + from plogical.acl import ACLManager + + if ACLManager.ISARM(): + command = 'wget -P /home/rustic https://github.com/rustic-rs/rustic/releases/download/%s/rustic-%s-aarch64-unknown-linux-gnu.tar.gz' % ( + version, version) + ProcessUtilities.executioner(command) + + command = 'tar xzf /home/rustic/rustic-%s-aarch64-unknown-linux-gnu.tar.gz -C /home/rustic//' % ( + version) + ProcessUtilities.executioner(command) + + else: + command = 'wget -P /home/rustic https://github.com/rustic-rs/rustic/releases/download/%s/rustic-%s-x86_64-unknown-linux-musl.tar.gz' % ( version, version) - ProcessUtilities.executioner(command) + ProcessUtilities.executioner(command) - command = 'tar xzf /home/rustic/rustic-%s-x86_64-unknown-linux-musl.tar.gz -C /home/rustic//' % ( - version) - ProcessUtilities.executioner(command) + command = 'tar xzf /home/rustic/rustic-%s-x86_64-unknown-linux-musl.tar.gz -C /home/rustic//' % ( + version) + ProcessUtilities.executioner(command) command = 'sudo mv /home/rustic/rustic /usr/bin/' ProcessUtilities.executioner(command) diff --git a/plogical/acl.py b/plogical/acl.py index 1ab721c09..c20537719 100644 --- a/plogical/acl.py +++ b/plogical/acl.py @@ -1085,4 +1085,18 @@ def ReplaceDocRootApache(vhostConf, domainName, NewDocRoot): pass + @staticmethod + def ISARM(): + + command = 'uname -a' + result = ProcessUtilities.outputExecutioner(command) + + if result.find('aarch64') > -1: + return True + else: + return False + + + +