This commit is contained in:
emdee 2023-12-30 22:09:49 +00:00
parent f11ab239af
commit 94c76b2e4b
30 changed files with 176 additions and 326 deletions

View file

@ -27,4 +27,4 @@ TOXCORE_GENTOO_FROM_MP: "{{BOX_GENTOO_FROM_MP}}"
TOXCORE_FEATURES:
- libvirt
- docker

View file

@ -84,7 +84,7 @@
PORTAGE_ELOG_CLASSES="warn error"
# NOT syslog
PORTAGE_ELOG_SYSTEM="save"
- name: "/etc/portage/make.conf base Gentoo2.yml CFLAGS"
blockinfile:
dest: /etc/portage/make.conf
@ -94,7 +94,7 @@
# -pipe
CFLAGS="-mtune=generic -O2"
CXXFLAGS="-mtune=generic -O2"
- name: "/etc/portage/make.conf base Gentoo.yml PORT_LOGDIR"
blockinfile:
dest: /etc/portage/make.conf
@ -104,7 +104,7 @@
PORT_LOGDIR="/var/log/portage"
PORTAGE_ELOG_CLASSES="log warn error info"
PORTAGE_ELOG_SYSTEM="echo:log,warn save:log,warn,error,info syslog:error"
- name: "/etc/portage/make.conf base Gentoo.yml ACCEPT_KEYWORDS"
blockinfile:
dest: /etc/portage/make.conf
@ -114,7 +114,7 @@
# In ACCEPT_KEYWORDS, ~amd64 is used for current 64-bit builds;
# There is no tilde for the stable build.
ACCEPT_KEYWORDS="~amd64"
- name: "/etc/portage/make.conf base Gentoo.yml GENTOO_MIRRORS"
blockinfile:
dest: /etc/portage/make.conf
@ -122,7 +122,7 @@
marker: "# {mark} ANSIBLE MANAGED BLOCK base Gentoo.yml [GENTOO_MIRRORS]"
block: |
GENTOO_MIRRORS="http://distfiles.gentoo.org"
- name: "/etc/portage/make.conf Gentoo2 base"
blockinfile:
dest: /etc/portage/make.conf
@ -131,7 +131,7 @@
block: |
# 2016-01 added for some py packages
COLLISION_IGNORE="/lib/modules/* *.py[co] __init__.py"
- name: "/etc/portage/make.conf Gentoo2 UNINSTALL_IGNORE"
blockinfile:
dest: /etc/portage/make.conf
@ -140,7 +140,7 @@
block: |
# 2017-01 added for kernel compiling
UNINSTALL_IGNORE="/usr/src /opt /usr/lib32 /usr/lib64/python2.7"
- name: "/etc/portage/make.conf Gentoo2 FEATURES-preserve-libs"
blockinfile:
dest: /etc/portage/make.conf
@ -149,7 +149,7 @@
block: |
# https://wiki.gentoo.org/wiki/Project:Toolchain/libcrypt_implementation
FEATURES="${FEATURES} preserve-libs"
- name: "/etc/portage/make.conf Gentoo2 FEATURES"
blockinfile:
dest: /etc/portage/make.conf
@ -166,6 +166,6 @@
CXXFLAGS="-mtune=generic -O2 -pipe"
FCFLAGS="${CFLAGS}"
FFLAGS="${CFLAGS}"
when: true

View file

@ -18,27 +18,27 @@
parted -s {{nbd_disk}} mkpart primary 2048s 100%
partprobe
mkfs.ext4 -FF {{nbd_disk}}p1
- name: "mount the disk"
shell: |
df | grep {{nbd_disk}}p1 && exit 0
[ -d {{BASE_NBD_MP}} ] || mkdir {{BASE_NBD_MP}}
mount {{nbd_disk}}p1 {{BASE_NBD_MP}}
[ -d {{BASE_NBD_MP}}/lost+found ]
- name: "check the disk"
shell: |
df | grep {{nbd_disk}}p1 || exit 1
[ -d {{BASE_NBD_MP}}/lost+found ] || exit 2
- name: check the downloads step5
shell: |
stage3_asc=stage3-amd64-openrc-20231217T170203Z.tar.xz.sha256
stage3_xz=stage3-amd64-openrc-20231217T170203Z.tar.xz
sha256sum -c $stage3_asc
tar xJpf $stage3 --xattrs-include='*.*' --numeric-owner -C {{BASE_NBD_MP}
portage_xz=portage-20231221.tar.xz
tar xpJf $portage -C {{BASE_NBD_MP}}/usr
@ -50,10 +50,10 @@
[ -d etc/portage/package.license ] || mkdir -p etc/portage/package.license
EOF
chdir: "{{BASE_NBD_MP}}"
creates: "{{BASE_NBD_MP}}/etc"
- name: chroot into the partition - step4
shell: |
df | grep {{nbd_disk}}p1 || exit 1
@ -74,7 +74,7 @@
- name: stop here
shell: |
exit 1
delegate_to: localhost
when:
- nbd_disk != ''

View file

@ -21,7 +21,7 @@
become_user: "{{ BOX_USER_NAME }}"
ignore_errors: true
check_mode: false
- name: "run toxcore_daily.bash"
environment: "{{ shell_proxy_env }}"
shell: |

View file

@ -16,7 +16,7 @@
when:
- false # this is vagrant only
- "ansible_virtualization_role|replace('NA', 'host') != 'host'"
- name: check guest-agent
# was toxcore_bin.bash
shell: |
@ -28,7 +28,7 @@
exit 0 # $retval
}
exit 0
when: "ansible_virtualization_role|replace('NA', 'host') != 'host'"
- name: run toxcore_check_modules.bash

View file

@ -5,8 +5,8 @@
- name: "toxcore main.yml"
debug:
verbosity: 1
msg: "toxcore main.yml BOX_OS_FAMILY={{BOX_OS_FAMILY}} {{BOX_GENTOO_FROM_MP}} {{ansible_virtualization_role|replace('NA', 'host')}}"
msg: "toxcore main.yml BOX_OS_FAMILY={{BOX_OS_FAMILY}} {{BOX_GENTOO_FROM_MP}} {{ansible_virtualization_role|replace('NA', 'host')}}"
- name: toxcore include_vars
include_vars: "{{item}}.yml"
with_items:
@ -80,7 +80,7 @@
DIR=$KDIR/misc
[ -d $DIR ] || { echo WARN: no directory $DIR ; exit 0 ; }
/var/local/bin/toxcore_sign_modules.bash {{ toxcore_kmods_in_host|flatten|join(' ') }}
when: false
# this changes with kernel 4 -> 5
@ -160,8 +160,8 @@
environment: "{{ shell_proxy_env }}"
shell: |
[ -f /usr/share/openpgp-keys/gentoo-release.asc ] && exit 0
gpg --import /usr/local/share/openpgp-keys/gentoo-release.asc
gpg --import /usr/local/share/openpgp-keys/gentoo-release.asc
# this should not run as root
# delegate_to: localhost? - no - per test
- name: "usr_local_toxcore.bash"
@ -177,7 +177,7 @@
become_user: "{{ BOX_USER_NAME }}"
ignore_errors: true
check_mode: false
- name: "include_tasks toxcore vms as root"
include_tasks:
file: "{{LOOP_ITEM}}.yml"
@ -226,7 +226,7 @@
# - "{{ 'docker_users' if 'docker' in TOXCORE_FEATURES else '' }}"
loop_control:
loop_var: LOOP_USER_F
- name: enable and start toxcore services
service:
name: "{{ item }}"
@ -275,7 +275,7 @@
# -m MAC address to use (default is to use a randomly-generated MAC)
# -p ansible users plaintext password
# -k Full path and name of the ansible user's public key file (required)
- name: run toxcore_create-vm.bash
delegate_to: localhost
shell: |
@ -295,7 +295,7 @@
-d {{BOX_NBD_OVERLAY_DIR}} \
-b virbr0 \
-p gentoo \
-o gentoo
-o gentoo
ignore_errors: true
when:
- "ansible_virtualization_role|replace('NA', 'host') == 'host'"

View file

@ -8,7 +8,7 @@
msg: "toxcore users.yml LOOP_USER_F={{LOOP_USER_F[0]}}"
- block:
- name: /etc/sysconfig/docker
blockinfile:
dest: /etc/sysconfig/docker
@ -108,7 +108,7 @@
# - windows-qt5
# - windows
- name: Run toxygen_wrapper on the tester
delegate_to: localhost
shell: |

View file

@ -11,7 +11,7 @@
shell: |
[ -e /dev/kvm ]
delegate_to: localhost
- name: "make a directory for /etc/pki/qemu"
file:
path: "{{item }}"
@ -120,7 +120,7 @@
- debug:
verbosity: 1
msg: "Ignoring error"
#libvirt
- block:

View file

@ -201,7 +201,7 @@ toxcore_aws_debs_inst:
- awscli
toxcore_pips2_inst: []
toxcore_pips3_inst:
- pycrypto
- pywinrm
@ -210,4 +210,4 @@ toxcore_pips3_inst:
- msgpack_python
- pysha3
- pycryptodomex