Exemplo n.º 1
0
def headless():

    # How do I enable the "multiverse" repository?
    # http://askubuntu.com/questions/89096/how-do-i-enable-the-multiverse-repository
    sudo('sed -i "/^# deb.*multiverse/ s/^# //" /etc/apt/sources.list')

    timezone()

    execute(ntpd)
    require_deb_packages(        '''

sudo
screen

htop
nmap
iotop
mc
ssh
nano
cpuid

curl
wget

nfs-kernel-server
nfs-common
                    ''')

    require.directory('bin')
    require.file('.profile', contents=cfg('profile.conf'))
Exemplo n.º 2
0
def ntpd():
    require_deb_packages(
        '''
        ntp
        ntpdate
                    '''
    )
    require.file('/etc/ntp.conf', contents=cfg('ntp.conf'), use_sudo=True)