Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Infrastructure: Migrate from NFS to ZFS for homes #575

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,9 @@ jobs:
- name: Run tests
timeout-minutes: 4
run: |
docker exec dojo-test ls -al /dev
docker exec dojo-test zpool status
docker exec dojo-test zfs list
export MOZ_HEADLESS=1
timeout 3m pytest -vrpP --durations=0 ./test || (docker exec dojo-test dojo compose logs && false)

Expand Down
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ RUN apt-get update && \
nfs-kernel-server \
unzip \
wget \
wireguard
wireguard \
zfsutils-linux

RUN curl -fsSL https://get.docker.com | /bin/sh && \
echo '{ "data-root": "/data/docker", "hosts": ["unix:///run/docker.sock"], "builder": {"Entitlements": {"security-insecure": true}} }' > /etc/docker/daemon.json && \
Expand Down
5 changes: 5 additions & 0 deletions dojo/dojo-init
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,11 @@ mv /data/.config.env /data/config.env
mkdir -p /data/workspace/nix
mkdir -p /data/workspacefs/bin

if ! zpool list dojo > /dev/null 2>&1; then
truncate -s 256G /data/dojo-zfs.img
zpool create dojo /data/dojo-zfs.img
fi

if [ ! -f /data/homes/homefs ]; then
echo "[+] Creating user home structure."
mkdir -p /data/homes
Expand Down
Loading