add roles/toxcore/

This commit is contained in:
emdee 2023-12-30 12:52:24 +00:00
parent ac375a87c7
commit 273e6b2282
51 changed files with 9643 additions and 4 deletions

View file

@ -0,0 +1,213 @@
# -*- mode: yaml; indent-tabs-mode: nil; tab-width: 2; coding: utf-8-unix -*-
---
# TOXCORE_FEATURES: ['virtualbox', 'libvirt', docker']
toxcore_system_users: "{{ BOX_USER_NAME }}"
toxcore_also_users: "{{ BOX_ALSO_USERS }}"
toxcore_standard_users_groups:
- disk
- "{{ 'libvirt-qemu' if 'libvirt' in TOXCORE_FEATURES else '' }}"
- "{{ 'kvm' if ( 'qemu' in TOXCORE_FEATURES or 'libvirt' in TOXCORE_FEATURES ) else '' }}"
- "{{ 'docker' if 'docker' in TOXCORE_FEATURES else '' }}"
toxcore_libvirt_services:
- "{{ 'libvirtd' if 'libvirt' in TOXCORE_FEATURES else '' }}"
- "{{ 'virtlogd' if 'libvirt' in TOXCORE_FEATURES else '' }}"
- "{{ 'docker' if 'docker' in TOXCORE_FEATURES else '' }}"
toxcore_debs_inst:
- gpg
- nbdkit
- nbd-client
- nbd-server
- python3-yaml
- gparted
- ebtables
- dnsmasq-base
# vagrant-libvirt/README.md
- libxslt-dev
- libxml2-dev
- zlib1g-dev
- iptables
- zstd
- bridge-utils
- sdparm
- hdparm
- libxml2
- zerofree
- openssh-sftp-server
- sshfs
- xmlstarlet
- libtss2-tcti-swtpm0
# toxcore
- libconfig-dev
- libgtest-dev
- ninja-build
- pkg-config
- zip
- grep
- file
- ca-certificates
- autotools-dev
- autoconf
- automake
- git
- bc
- wget
- rsync
- cmake
- make
- pkg-config
- libtool
- ssh
- gzip
- tar
- unzip
- libcurl4-gnutls-dev
- coreutils
- libavutil-dev
- libsodium-dev
- libffms2-4
- libgpac10
- libx264-dev
- x264
- libv4lconvert0
- libv4l-dev
- libv4l-dev
- libv4l2rds0
- v4l-conf
- v4l-utils
- libv4l-dev
- libtool
- autotools-dev
- automake
- checkinstall
- check
- git
- yasm
- libv4lconvert0
- libv4l-dev
- libopus-dev
- libvpx-dev
- pkg-config
- libx264-dev
- libavcodec-dev
- libavdevice-dev
# nbd
- genisoimage
- bridge-utils
- guestfsd
- libvirt-clients
- libvirt-daemon
- libvirt-daemon-system
- libvirt-daemon-driver-storage-zfs
- python3-libvirt
- virt-manager
- virtinst
- python3-hacking
# - cloud-init
toxcore_qemu_debs_inst:
- qemu-kvm
- qemu
- qemu-block-extra
- qemu-system-common
- qemu-system-data
- qemu-system-x86
- qemu-utils
- guestfsd
- grub-firmware-qemu
- nbd-client
- aqemu
- seabios
- squashfs-tools
- attr
- zerofree
- nbdkit
- sgabios
- lzop
- firmware-realtek
- firmware-linux-free
proxy_libvirt_debs_inst:
- libvirt-daemon-system
- libvirt-daemon
- libvirt-daemon-driver-vbox
- libvirt-daemon-driver-qemu
- libvirt-clients
- libvirt-daemon-driver-storage-zfs
- python3-libvirt
- virt-manager
- virtinst
- usbutils
- usb.ids
- guestfsd
- libguestfs-perl
- libguestfs-tools
#
- genisoimage
- bridge-utils
- guestfsd
- python3-hacking
#? - cloud-init
toxcore_lxd_debs_absent:
- lxd
- lxd-client
- lxcfs
- liblxc1
- liblxc-common
toxcore_lxd_debs_inst:
- lxcfs
- zfsutils-linux
# see proxy_libvirt_debs_inst
toxcore_libvirt_debs_inst:
- python3-libvirt
- libvirt-dev
- libguestfs
- libguestfs-tools
# OUCH 4G!
- libguestfs-appliance
- virt-top
toxcore_packer_debs_inst:
- jq
toxcore_docker_debs_inst:
- aufs-tools
- cgroup-lite
- linux-image-extra-virtual
- docker.io
# - docker-compose
toxcore_ansible_debs_inst:
- jinja
- pycrypto
- python-ecdsa
- python-httplib2
- python-jinja2
- python-markupsafe
- python-paramiko
toxcore_aws_debs_inst:
# for aws
- boto
- bs4
- awscli
toxcore_pips2_inst: []
toxcore_pips3_inst:
- pycrypto
- pywinrm
- requests-unixsocket
- ovirt-engine-sdk-python
- msgpack_python
- pysha3
- pycryptodomex

View file

@ -0,0 +1,101 @@
# -*- mode: yaml; indent-tabs-mode: nil; tab-width: 2; coding: utf-8-unix -*-
---
toxcore_system_users: "{{ base_system_users }}"
toxcore_also_users: "{{ base_also_users }}"
toxcore_standard_users_groups:
- disk
- "{{ 'libvirt' if 'libvirt' in TOXCORE_FEATURES else '' }}"
- "{{ 'qemu' if ( 'qemu' in TOXCORE_FEATURES or 'libvirt' in TOXCORE_FEATURES ) else '' }}"
- "{{ 'kvm' if ( 'qemu' in TOXCORE_FEATURES or 'libvirt' in TOXCORE_FEATURES ) else '' }}"
- "{{ 'docker' if 'docker' in TOXCORE_FEATURES else '' }}"
toxcore_libvirt_services:
- libvirtd
# - qemu-guest-agent
toxcore_pkgs_inst_guest: []
toxcore_pkgs_inst:
- net-firewall/iptables
- app-portage/gentoolkit
- sys-apps/gptfdisk
- app-admin/testdisk
- app-arch/zstd
- net-firewall/ebtables
- net-misc/bridge-utils
- sys-apps/sdparm
- sys-apps/hdparm
### virt-manager
- media-libs/libvpx
- net-libs/libpsl
- x11-libs/libxcb
- x11-libs/libxkbcommon
- dev-libs/libxml2
- dev-python/argcomplete
- dev-python/libvirt-python
- dev-python/pygobject
- dev-python/requests
- gnome-base/dconf
- net-libs/gtk-vnc
- net-misc/spice-gtk
- sys-apps/dbus
- x11-libs/gtk+
- x11-libs/gtksourceview
- x11-libs/vte
toxcore_pkgs_masked:
- x11-drivers/xf86-video-amdgpu
- x11-drivers/xf86-video-mga
- x11-drivers/xf86-video-radeon
- x11-drivers/xf86-video-siliconmotion
- x11-drivers/xf86-video-via
toxcore_zfs_pkgs_inst:
- sys-fs/zfs-kmod
- sys-fs/zfs
toxcore_qemu_pkgs_inst:
- app-emulation/qemu
- app-emulation/aqemu
- app-emulation/spice
- net-misc/spice-gtk
- qemu-guest-agent
toxcore_libvirt_pkgs_inst:
- app-emulation/libvirt
- dev-python/libvirt
- app-emulation/virt-manager
- app-emulation/virt-viewer
- x11-drivers/xf86-video-qxl
# - sys-block/open-iscsi
- sys-firmware/edk2-ovmf
- app-emulation/libguestfs
- sys-block/nbd
#? - app-emulation/libguestfs-appliance
- dev-python/libvirt-python
- app-emulation/virtiofsd
toxcore_docker_pkgs_inst:
- sys-process/tini
- app-emulation/docker
#? - dev-python/docker-pycreds
- dev-python/dockerpty
- dev-python/docker-py
- app-containers/docker
# - app-containers/docker-compose
toxcore_pips2_inst: []
toxcore_pips3_inst:
- pycrypto
- pywinrm
- requests-unixsocket
- ovirt-engine-sdk-python
- msgpack_python
- pysha3
- pycryptodomex
- pyanalyze

View file

@ -0,0 +1,37 @@
# -*- mode: yaml; indent-tabs-mode: nil; tab-width: 2; coding: utf-8-unix -*-
---
# from BOX
toxcore_system_users: "{{ base_system_users }}"
toxcore_standard_users: "{{ base_standard_users }}"
toxcore_etc_initd_libvirt_name: libvirtd
toxcore_kmods_in_host:
- "{{ 'kvm' if ( ( 'qemu' in TOXCORE_FEATURES or 'libvirt' in TOXCORE_FEATURES ) and 'virtualbox' not in TOXCORE_FEATURES ) else '' }}"
- "{{ 'qxl' if ( 'qemu' in TOXCORE_FEATURES or 'libvirt' in TOXCORE_FEATURES ) else '' }}"
- "{{ 'nbd' if ( 'qemu' in TOXCORE_FEATURES or 'libvirt' in TOXCORE_FEATURES ) else '' }}"
toxcore_kmods_not_in_host:
# I'm not sure kvm should be missing anymore 5+
# FixMe: how do these conflict? qemu libvirt
- "{{ 'kvm' if 'virtualbox' in TOXCORE_FEATURES else '' }}"
toxcore_gpg_keys_system:
- uid: "30737D12308C9D0C882FC34B57CB0A121BAECB2E"
primary: "70ACBB6BFEE7BC572A8941D19266C4FA11FD00FD"
name: "Daniel Robbins (metro:node) <drobbins@funtoo.org>"
key: "9266C4FA11FD00FD"
toxcore_services_enabled: []
# - qemu-guest-agent
toxcore_services_started:
- "{{ toxcore_libvirt_services if 'libvirt' in TOXCORE_FEATURES else [] }}"
# not on Gentoo 5
#? - "{{ 'docker' if 'docker' in TOXCORE_FEATURES else '' }}"
toxcore_services_stopped:
- "{{ toxcore_libvirt_services if 'libvirt' not in TOXCORE_FEATURES else [] }}"

View file

@ -0,0 +1,25 @@
# -*-mode: text; fill-column: 75; tab-width: 8; coding: utf-8-dos -*-
test::
update:: funtoo
p_src.yaml:: /p/src/_p_src.yaml
( cd /p/src && $(MAKE) $(MFLAGS) funtoo )
world.lis:: /var/lib/portage/world Makefile
cp -p /var/lib/portage/world world.lis
grep -h '^ *- .*/' main.yml base.yml p_src.yaml \
| sed -e 's@/@\\/@' -e 's@^ *- @/@' -e 's@$$@/d@' > world.sed
sed -f world.sed -i world.lis
funtoo:: world.lis Makefile
cp /dev/null python_world.lis
grep ^dev-python world.lis | while read file ; do \
grep -q "^- $$file" p_src.yaml && continue ; \
echo "$$file" >> python_world.lis ; \
done
clean::
# find * -type f -name \*~ -exec rm '{}' \;
rm -f *~ world.sed

View file

@ -0,0 +1,155 @@
# -*- mode: yaml; indent-tabs-mode: nil; tab-width: 2; coding: utf-8-unix -*-
---
# , 'lxd' 'vagrant'
TOXCORE_FEATURES: ['libvirt'] # 'docker', 'packer'
toxcore_system_users: "{{ base_system_users }}"
toxcore_also_users: "{{ base_also_users }}"
toxcore_libvirt_services:
- libvirtd
toxcore_debs_inst:
- python-yaml
- gparted
- libvncserver
- ebtables
- dnsmasq-base
# vagrant-libvirt/README.md
- libxslt-dev
- libxml2-dev
- zlib1g-dev
- iptables
- zstd
- ebtables
- bridge-utils
- sdparm
- hdparm
- libxml2
- sdparm
- hdparm
- libxml2
- zerofree
- openssh-sftp-server
- sshfs
- xmlstarlet
- libtss2-tcti-swtpm0
# toxcore
- libconfig-dev
- libgtest-dev
- ninja-build
- pkg-config
- zip
- grep
- file
- ca-certificates
- autotools-dev
- autoconf
- automake
- git
- bc
- wget
- rsync
- cmake
- make
- pkg-config
- libtool
- ssh
- gzip
- tar
- unzip
- libcurl4-gnutls-dev
- coreutils
- libavutil-dev
- libsodium-dev
- libffms2-4
- libgpac10
- libx264-dev
- x264
- libv4lconvert0
- libv4l-dev
- libv4l-dev
- libv4l2rds0
- v4l-conf
- v4l-utils
- libv4l-dev
- libtool
- autotools-dev
- automake
- checkinstall
- check
- git
- yasm
- libv4lconvert0
- libv4l-dev
- libopus-dev
- libvpx-dev
- pkg-config
- libx264-dev
- libavcodec-dev
- libavdevice-dev
toxcore_lxd_debs_absent:
- lxd
- lxd-client
- lxcfs
- liblxc1
- liblxc-common
toxcore_lxd_pkgs_inst:
- lxcfs
# - lxd
# - lxd-client
- zfsutils-linux
# or snapd
toxcore_qemu_debs_inst:
- qemu-kvm
toxcore_libvirt_debs_inst:
#? - libvirt
- libvirt-bin
- libvirt-dev
- virt-manager
- libguestfs
- libguestfs-tools
# OUCH 4G!
# - libguestfs-appliance
- python-libvirt
- qemu
toxcore_virtualbox_debs_inst:
- virtualbox
- virtualbox-modules
- virtualbox-ext-pack
# virtualbox bridged networking
toxcore_packer_debs_inst:
- jq
toxcore_docker_debs_inst:
- aufs-tools
- cgroup-lite
- libsystemd-journal0
- linux-image-extra-virtual
- docker.io
toxcore_ansible_debs_inst:
- jinja
- pycrypto
- paramiko
- python-ecdsa
- python-httplib2
- python-jinja2
- python-markupsafe
- python-paramiko
toxcore_aws_debs_inst:
# for aws
- boto
- bs4
- requests_ntlm
- awscli