Commit 8a5c4240 authored by Christian Kuhn's avatar Christian Kuhn
Browse files

[TASK] Update to sysbox 0.4.0 native package

parent 12bd0f72
......@@ -99,6 +99,16 @@
value: '4194304'
state: present
- name: Add shiftfs for sysbox
modprobe:
name: shiftfs
state: present
- name: shiftfs on boot
template:
src: root-kernel-modules-shiftfs.j2
dest: "/etc/modules-load.d/shiftfs.conf"
- name: root gitconfig for convenience
template:
src: root-gitconfig.j2
......@@ -111,44 +121,16 @@
- name: Check if sysbox exists
stat:
path: /usr/local/sbin/sysbox
path: /usr/bin/sysbox-runc
register: sysbox_result
- name: Install sysbox
when: not sysbox_result.stat.exists
shell: |
cd /root
git clone https://github.com/nestybox/sysbox.git
cd sysbox
git checkout d5c74b5e9025d663efd3de6ce5fa8bc6f7fcea3b
sed -i 's/git@github.com:/https:\/\/github.com\//' .gitmodules
git submodule update --init
sed -i 's/git@github.com:/https:\/\/github.com\//' sysbox-fs/.gitmodules
sed -i 's/git@github.com:/https:\/\/github.com\//' sysbox-libs/.gitmodules
git -C sysbox-fs submodule update --init
git -C sysbox-libs submodule update --init
make sysbox
make install
docker image prune -a -f
cd ..
rm -rf sysbox
mkdir sysbox
cd sysbox
wget -q https://github.com/nestybox/sysbox/releases/download/v0.2.1/sysbox_0.2.1-0.ubuntu-focal_amd64.deb -O sysbox.deb
ar x sysbox.deb
tar xf control.tar.xz
tar xf data.tar.xz
cp lib/sysctl.d/99-sysbox.conf /lib/sysctl.d/
cp lib/systemd/system/sysbox-fs.service /lib/systemd/system/
cp lib/systemd/system/sysbox-mgr.service /lib/systemd/system/
cp lib/systemd/system/sysbox.service /lib/systemd/system/
./postinst configure
cd ..
rm -rf sysbox
rm -rf /pkg
systemctl enable sysbox-fs.service
systemctl enable sysbox-mgr.service
systemctl enable sysbox.service
cd /root
wget https://github.com/nestybox/sysbox/releases/download/v0.4.0/sysbox-ce_0.4.0-0.ubuntu-focal_amd64.deb
apt-get install ./sysbox-ce_0.4.0-0.ubuntu-focal_amd64.deb
jq --indent 4 '. + {"default-runtime": "sysbox-runc"}' /etc/docker/daemon.json > /tmp/daemon.json
cp /tmp/daemon.json /etc/docker/daemon.json
echo "DefaultLimitNOFILE=524288:524288" >> /etc/systemd/system.conf
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment