add kunsi-p14s, add bundle:arch-with-gui
Some checks failed
kunsi/bundlewrap/pipeline/head There was a failure building this commit

This commit is contained in:
Franzi 2022-02-12 14:06:53 +01:00
parent 87bf6fac68
commit c073599f6f
Signed by: kunsi
GPG key ID: 12E3D2136B818350
85 changed files with 366 additions and 9 deletions

View file

@ -0,0 +1,3 @@
[Autologin]
User=${username}
Session=${session}

View file

@ -0,0 +1,94 @@
from os import listdir
from os.path import join
actions = {
'fc-cache_flush': {
'command': 'fc-cache -f',
'triggered': True,
'needs': {
'pkg_pacman:fontconfig',
},
},
'i3pystatus_create_virtualenv': {
'command': '/usr/bin/python3 -m virtualenv -p python3 /opt/i3pystatus/venv/',
'unless': 'test -d /opt/i3pystatus/venv/',
'needs': {
'directory:/opt/i3pystatus/src',
},
},
'i3pystatus_install': {
'command': ' && '.join([
'cd /opt/i3pystatus/src',
'/opt/i3pystatus/venv/bin/pip install --upgrade pip {}'.format(' '.join(sorted(node.metadata.get('arch-with-gui/i3pystatus/deps', set())))),
'/opt/i3pystatus/venv/bin/pip install --upgrade -e .',
]),
'needs': {
'action:i3pystatus_create_virtualenv',
},
'triggered': True,
},
}
directories = {
'/etc/sddm.conf.d': {
'purge': True,
},
'/opt/i3pystatus/src': {},
'/usr/share/fonts/bundlewrap': {
'purge': True,
'triggers': {
'action:fc-cache_flush',
},
},
}
svc_systemd = {
'sddm': {
'needs': {
'pkg_pacman:sddm',
},
},
}
git_deploy = {
'/opt/i3pystatus/src': {
'repo': 'https://github.com/enkore/i3pystatus.git',
'rev': 'current',
'triggers': {
'action:i3pystatus_install',
},
},
}
for filename in listdir(join(repo.path, 'data', 'arch-with-gui', 'files', 'fonts')):
if filename.startswith('.'):
continue
if filename.endswith('.vault'):
font_name = filename[:-6]
attrs = {
'content': repo.vault.decrypt_file_as_base64(join('arch-with-gui', 'files', 'fonts', filename)),
'content_type': 'base64',
}
else:
font_name = filename
attrs = {
'source': join('fonts', filename),
'content_type': 'binary',
}
files[f'/usr/share/fonts/bundlewrap/{font_name}'] = {
'triggers': {
'action:fc-cache_flush',
},
**attrs,
}
if node.metadata.get('arch-with-gui/autologin', {}):
files['/etc/sddm.conf.d/autologin.conf'] = {
'context': node.metadata.get('arch-with-gui/autologin'),
'content_type': 'mako',
'before': {
'svc_systemd:sddm',
},
}

View file

@ -0,0 +1,49 @@
assert node.os == 'arch'
defaults = {
'pacman': {
'packages': {
# fonts
'fontconfig': {},
'ttf-dejavu': {
'needed_by': {
'pkg_pacman:sddm',
},
},
# login management
'sddm': {},
# networking
'netctl': {},
'rfkill': {},
'wpa_supplicant': {},
'wpa_actiond': {},
# shell and other gui stuff
'fish': {},
'kitty': {},
'light': {},
'redshift': {},
'rofi': {},
# sound
'pavucontrol': {},
'pulseaudio': {},
'pulseaudio-zeroconf': {},
# window management
'i3-wm': {},
'i3lock': {},
'xss-lock': {},
# Xorg
'xf86-input-libinput': {},
'xorg-server': {},
'xorg-setxkbmap': {},
'xorg-xev': {},
'xorg-xinput': {},
'xorg-xset': {},
},
},
}

View file

@ -39,7 +39,6 @@ pkg_pacman = {
'ldns': {}, 'ldns': {},
'less': {}, 'less': {},
'libtool': {}, 'libtool': {},
'linux': {},
'logrotate': {}, 'logrotate': {},
'lsof': {}, 'lsof': {},
'm4': {}, 'm4': {},
@ -78,14 +77,10 @@ pkg_pacman = {
'zip': {}, 'zip': {},
} }
if node.metadata.get('pacman/install_gui', False): if node.metadata.get('pacman/linux-lts', False):
pkg_pacman.update({ pkg_pacman['linux-lts'] = {}
'fish': {}, else:
'netctl': {}, pkg_pacman['linux'] = {}
'rfkill': {},
'wpa_supplicant': {},
'wpa_actiond': {},
})
for pkg, config in node.metadata.get('pacman/packages', {}).items(): for pkg, config in node.metadata.get('pacman/packages', {}).items():
pkg_pacman[pkg] = config pkg_pacman[pkg] = config

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

144
nodes/kunsi-p14s.py Normal file
View file

@ -0,0 +1,144 @@
nodes['kunsi-p14s'] = {
'hostname': '172.19.138.90',
'bundles': {
'arch-with-gui',
'lldp',
'lm-sensors',
#'nfs-client',
'telegraf-battery-usage',
'zfs',
},
'groups': {
'arch',
},
'metadata': {
'arch-with-gui': {
'autologin': {
'username': 'kunsi',
'session': 'i3.desktop',
},
'i3pystatus': {
'deps': {
'colour',
'netifaces',
'basiciw',
},
},
},
'firewall': {
'port_rules': {
# obs websocket thingie - just allow all RFC1918 ips here
#'4444': {
# '10.0.0.0/8',
# '172.16.0.0/12',
# '192.168.0.0/16',
#},
# For the occasional file-share using `python -m http.server`
'8000': {'*'},
},
},
#'hosts': {
# 'entries': {
# '10.101.64.10': {
# 'www.wifionice.de',
# 'wifionice.de',
# },
# },
#},
'icinga_options': {
'exclude_from_monitoring': True,
},
'interfaces': {
'enp2s0f0': {
'dhcp': True,
},
'enp5s0': {
'ips': {
'172.19.138.90',
},
'gateway4': '172.19.138.1',
},
# there is also wlp3s0, but that's managed by netctl
},
#'nfs-client': {
# 'mounts': {
# 'nas-scansnap': {
# 'mountpoint': '/mnt/scansnap',
# 'serverpath': '172.19.138.20:/srv/scansnap',
# 'mount_options': {
# 'retry=0',
# 'rw',
# },
# },
# 'nas-storage': {
# 'mountpoint': '/mnt/nas',
# 'serverpath': '172.19.138.20:/storage/nas',
# 'mount_options': {
# 'retry=0',
# 'ro',
# },
# },
# },
#},
'openssh': {
'restrict-to': {
'rfc1918',
'ipv6',
},
},
'pacman': {
'linux-lts': True,
'packages': {
# for hardware support
'amd-ucode': {},
'mesa': {},
# various video drivers
'libva-mesa-driver': {},
'mesa-vdpau': {},
'xf86-input-wacom': {},
'xf86-video-amdgpu': {},
# for i3pystatus
'iw': {},
'wireless_tools': {},
# all that other random stuff one needs
'browserpass': {},
'claws-mail': {},
'claws-mail-themes': {},
'ferdi-bin': {},
'mosh': {},
'mosquitto': {},
'pass': {},
},
},
'systemd-networkd': {
'enable-resolved': True,
},
'timezone': 'Europe/Berlin',
'users': {
'kunsi': {
'password': vault.decrypt('encrypt$gAAAAABgLmmuQGRUStrQawoPee-758emIYn2u8-8ebrgzNAFSp7ifeFDdXXvs-zL3QogwNYlCtBHboH2xfy1rSj6OF5bbNO-tg=='),
'shell': '/usr/bin/fish',
},
'sophie': {
'delete': True,
},
},
'zfs': {
'snapshots': {
'retain_per_dataset': {
'zroot/user/kunsi': {
# juuuuuuuust to be sure
'hourly': 100,
},
},
'snapshot_never': {
'zroot/system/journal',
},
},
},
},
'os': 'arch',
}