Beispiel #1
0
 def __init__(self, source_path):
     super().__init__()
     self.source_path = source_path
     self.deps = [
         ant.Command('openvpn', '--version').check_exists().if_false(
             ant.Install('openvpn')),
     ]
Beispiel #2
0
 def __init__(self):
     self.deps = [
         ant.Command('apt', 'update')
             .with_timout(install_timout())
             .with_passthrough()
             .with_sudo()
     ]
Beispiel #3
0
 def march(self, queen):
     return [
         ant.Command()
             .with_args('apt', 'install', self.package.get_name())
             .with_timout(install_timout())
             .with_passthrough()
             .with_sudo()
     ]
Beispiel #4
0
def get_installed_check():
    return ant.Command('pacman', '--version').check_success()
Beispiel #5
0
def get_installed_check():
    return ant.Command('apt', '-v').check_success()
Beispiel #6
0
#!/usr/bin/python3

import ant

queen = ant.Queen()
queen.add(
    ant.Command('cowsay', '-h').check_exists().if_false(ant.Install('cowsay')))
queen.add(
    ant.Command('syncthing', '--version').check_success().if_false(
        ant.Install('syncthing')))
queen.add(ant.OpenVpn('/home/wmww/light/Config/mullvad'))
queen.march()