diff options
| author | Roman Scherer <roman@burningswell.com> | 2025-02-27 19:24:46 +0100 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2025-02-28 23:03:36 +0100 |
| commit | 2e8439d37ec79f6e0896f29d26bca2d024bd27fe (patch) | |
| tree | def0c0f6a7f630c75dac399be68fd80c5356e05c /gnu/machine | |
| parent | a4168d8ba75bff6d1a855dd6343ffc5d3b6b53c8 (diff) | |
machine: hetzner: Fix deployment on smaller instances.
* gnu/machine/hetzner.scm (hetzner-machine-rescue-install-os): Avoid out of
disk space error by bind mounting /mnt/tmp/gnu/store to /gnu/store.
* tests/machine/hetzner.scm: Test with smaller instances.
* doc/guix.texi (Invoking guix deploy): Mention unsupported instance.
Change-Id: If8bfb6733de493b51813b3e82e255849192f7cba
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'gnu/machine')
| -rw-r--r-- | gnu/machine/hetzner.scm | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gnu/machine/hetzner.scm b/gnu/machine/hetzner.scm index 1d9a3f43857..bc8d2efbd34 100644 --- a/gnu/machine/hetzner.scm +++ b/gnu/machine/hetzner.scm | |||
| @@ -551,6 +551,13 @@ chmod 700 /mnt/root/.ssh | |||
| 551 | cp /root/.ssh/authorized_keys /mnt/root/.ssh/authorized_keys | 551 | cp /root/.ssh/authorized_keys /mnt/root/.ssh/authorized_keys |
| 552 | chmod 600 /mnt/root/.ssh/authorized_keys | 552 | chmod 600 /mnt/root/.ssh/authorized_keys |
| 553 | 553 | ||
| 554 | # Small instance don't have much disk space. Bind mount the store of the | ||
| 555 | # rescue system to the tmp directory of the new Guix system. | ||
| 556 | mkdir -p /mnt/tmp/gnu/store | ||
| 557 | mkdir -p /gnu/store | ||
| 558 | mount --bind /mnt/tmp/gnu/store /gnu/store | ||
| 559 | |||
| 560 | apt-get install guix --assume-yes | ||
| 554 | cat > /tmp/guix/deploy/hetzner-os.scm << EOF | 561 | cat > /tmp/guix/deploy/hetzner-os.scm << EOF |
| 555 | (use-modules (gnu) (guix utils)) | 562 | (use-modules (gnu) (guix utils)) |
| 556 | (use-package-modules ssh) | 563 | (use-package-modules ssh) |
| @@ -605,7 +612,7 @@ fdisk -l /dev/sda" | |||
| 605 | (format #f "#!/usr/bin/env bash | 612 | (format #f "#!/usr/bin/env bash |
| 606 | set -eo pipefail | 613 | set -eo pipefail |
| 607 | apt-get update | 614 | apt-get update |
| 608 | apt-get install guix cloud-initramfs-growroot --assume-yes")) | 615 | apt-get install cloud-initramfs-growroot --assume-yes")) |
| 609 | (format #t "successfully installed rescue system packages on '~a'\n" name))) | 616 | (format #t "successfully installed rescue system packages on '~a'\n" name))) |
| 610 | 617 | ||
| 611 | (define (hetzner-machine-delete machine server) | 618 | (define (hetzner-machine-delete machine server) |
