summaryrefslogtreecommitdiff
path: root/guix/scripts/system.scm
AgeCommit message (Collapse)Author
2018-03-15guix system: Add '--skip-checks'.Ludovic Courtès
Fixes <https://bugs.gnu.org/30760>. Reported by Tomáš Čech <sleep_walker@gnu.org>. * guix/scripts/system.scm (perform-action): Add #:skip-safety-checks? and honor it. (show-help, %options): Add --skip-checks. (process-action): Pass #:skip-safety-checks? to 'perform-action'. * doc/guix.texi (Invoking guix system): Document --skip-checks.
2018-03-07linux-initrd: Factorize 'check-device-initrd-modules'.Ludovic Courtès
* gnu/system/mapped-devices.scm (check-device-initrd-modules): Move to... * gnu/system/linux-initrd.scm (check-device-initrd-modules): ... here. New procedure. * po/guix/POTFILES.in: Add it. * guix/scripts/system.scm (check-initrd-modules)[check-device]: Remove. Use 'check-device-initrd-modules' instead.
2018-03-02guix system: Check for the lack of modules in the initrd.Ludovic Courtès
* guix/scripts/system.scm (check-mapped-devices): Take an OS instead of a list of <mapped-device>. Pass #:needed-for-boot? and #:initrd-modules to CHECK. (check-initrd-modules): New procedure. (perform-action): Move 'check-mapped-devices' call first. Add call to 'check-initrd-modules'. * gnu/system/mapped-devices.scm (check-device-initrd-modules): New procedure. (check-luks-device): Add #:initrd-modules and #:needed-for-boot?. Use them to call 'check-device-initrd-modules'.
2018-01-21services: shepherd: Make 'shepherd-configuration-file' non-monadic.Ludovic Courtès
Suggested by atw on #guix. * gnu/services/shepherd.scm (shepherd-service-file): Use 'scheme-file' instead of 'gexp->file'. (shepherd-configuration-file): Likewise, and adjust to non-monadic style. (shepherd-boot-gexp): Adjust accordingly. * guix/scripts/system.scm (upgrade-shepherd-services): Use 'lower-object' in addition to 'shepherd-service-file'.
2018-01-19gnu: Consistently Write ‘file system(s)’.Tobias Geerinckx-Rice
It is the GNU way. * doc/guix.texi (Build Systems, DNS Services): Write ‘file system(s)’. * gnu/build/vm.scm (create-ext-file-system, create-fat-file-system): Likewise. * gnu/packages/backup.scm (dirvish, rsnapshot)[description]: Likewise. * gnu/packages/check.scm (python-testpath)[description]: Likewise. * gnu/packages/disk.scm (pydf)[description]: Likewise. * gnu/packages/file-systems.scm (disorderfs)[synopsis, description]: Likewise. (glusterfs)[description]: Likewise. * gnu/packages/haskell.scm (ghc-directory, ghc-system-fileio-bootstrap) (ghc-system-fileio)[synopsis]: Likewise. (ghc-fsnotify)[description]: Likewise. * gnu/packages/linux.scm (proot)[description]: Likewise. (jmtpfs)[synopsis, description]: Likewise. * gnu/packages/mate.scm (caja, caja-extensions)[description]: Likewise. * gnu/packages/storage.scm (ceph)[description]: Likewise. * gnu/packages/sync.scm (lsyncd)[description]: Likewise. * gnu/packages/syncthing.scm (syncthing)[synopsis]: Likewise. (go-github-com-zillode-notify)[description]: Likewise. * gnu/services/nfs.scm (pipefs-service-type): Likewise. * guix/scripts/system.scm (perform-action): Likewise.
2017-12-22guix system: Check mapped devices upon 'init' and 'reconfigure'.Ludovic Courtès
* guix/scripts/system.scm (check-mapped-devices): New procedure. (perform-action): Add call to 'check-mapped-devices'.
2017-12-15scripts: system: Add --expression option.Mathieu Othacehe
* guix/scripts/system.scm (show-help): Add expression option. (%options): Ditto. (guix-system): Allow commands taking a file as an argument to use an expression instead. (process-action): Read operating-system from expression or file. * doc/guix.texi (Invoking guix system): Introduce the expression option.
2017-12-15bootloader: Factorize write-file-on-device.Mathieu Othacehe
* gnu/bootloader/extlinux.scm (install-extlinux): Factorize bootloader writing in a new procedure write-file-on-device defined in (gnu build bootloader). * gnu/build/bootloader.scm: New file. * gnu/local.mk (GNU_SYSTEM_MODULES): Add new file. * gnu/system/vm.scm (qemu-img): Adapt to import and use (gnu build bootloader) module during derivation building. * gnu/scripts/system.scm (bootloader-installer-derivation): Ditto.
2017-12-07scripts: All commands enable build hooks by default.Ludovic Courtès
* guix/scripts/archive.scm (%default-options): Add 'build-hook?'. * guix/scripts/copy.scm (%default-options): Likewise. * guix/scripts/environment.scm (%default-options): Likewise. * guix/scripts/pack.scm (%default-options): Likewise. * guix/scripts/package.scm (%default-options): Likewise. * guix/scripts/pull.scm (%default-options): Likewise.
2017-12-04bootloader: extlinux: Stop using dd binary.Mathieu Othacehe
* gnu/bootloader/extlinux.scm (dd): Remove it, (install-extlinux): replace dd call by Guile I/O procedures. * gnu/system/vm.scm (qemu-image): Add (ice-9 binary-ports) to used-modules list to provide "get-bytevector-n" and "put-bytevector". * guix/scripts/system.scm (bootloader-installer-derivation): Ditto.
2017-12-01guix system: 'init' displays a progress bar while copying.Ludovic Courtès
Until now it would print the name of each store item being copied, which was verbose and unhelpful. * guix/scripts/system.scm (copy-closure): Use 'progress-reporter/bar' and 'call-with-progress-reporter'. (guix-system): Parameterize 'current-terminal-columns'.
2017-12-01guix system: Simplify closure copy.Ludovic Courtès
* guix/scripts/system.scm (copy-item): Add 'references' argument and remove 'references*' call. Turn into a non-monadic procedure. (copy-closure): Remove initial call to 'references*'. Only pass ITEM to 'topologically-sorted*' since that's equivalent. Compute the list of references corresponding to TO-COPY and pass it to 'copy-item'.
2017-10-05guix system: Error out when passed a wrong file system UUID/label.Ludovic Courtès
* guix/scripts/system.scm (check-file-system-availability): New procedure. (perform-action): Use it.
2017-09-16guix system: Add 'search' command.Ludovic Courtès
* guix/scripts/system.scm (resolve-subcommand): New procedure. (process-command): Handle 'search'. (guix-system): Likewise. (show-help): Augment. * guix/scripts/system/search.scm: New file. * po/guix/POTFILES.in: Add it. * Makefile.am (MODULES): Add it. * guix/ui.scm (%text-width): Export. * doc/guix.texi (Invoking guix system): Document it. (Service Types and Services): Mention 'guix system search'. * tests/guix-system.sh: Test it.
2017-09-12guix system: Pretty-print device UUIDs.Ludovic Courtès
* guix/scripts/system.scm (display-system-generation): Check if ROOT-DEVICE is a UUID and pretty-print it if it is.
2017-09-01scripts: Remove 'max-silent-time' from the default options.Maxim Cournoyer
Fixes <http://bugs.gnu.org/27157>. Having a finite default `max-silent-time' value for scripts such as 'guix environment' could lead to timeouts when building subtitutes; this was undesirable. This change also fixes client behavior to match the documentation, which is that by default the daemon's settings are honored. * guix/scripts/archive.scm (%default-options): Remove max-silent-time entry. * guix/scripts/copy.scm (%default-options): Likewise. * guix/scripts/environment.scm (%default-options): Likewise. * guix/scripts/pack.scm (%default-options): Likewise. * guix/scripts/package.scm (%default-options): Likewise. * guix/scripts/pull.scm (%default-options): Likewise. * guix/scripts/system.scm (%default-options): Likewise. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2017-08-23gnu: bootloader: Deprecate "device" field in favor of "target".Andy Wingo
* gnu/bootloader.scm (<bootloader-configuration>): Deprecate "device" field in favor of "target" field. This is mostly a renaming but also a generalization to support UEFI targets being paths to a mounted partition instead of a device name. * gnu/system/examples/bare-bones.tmpl: * gnu/system/examples/desktop.tmpl: * gnu/system/examples/lightweight-desktop.tmpl: * gnu/system/examples/vm-image.tmpl: * gnu/system/install.scm: * gnu/tests.scm: * gnu/tests/install.scm: * gnu/tests/nfs.scm: * tests/system.scm: Adapt all invocations of bootloader-configuration. * guix/scripts/system.scm (perform-action): Rename device argument to bootloader-target. (process-action): Adapt caller. * doc/guix.texi (Proceeding with the Installation): * doc/guix.texi (Bootloader Configuration): Update documentation.
2017-08-23gnu: scripts: Cleanup regarding "gnu system" bootloader devices.Andy Wingo
* guix/scripts/system.scm (install-bootloader, install): Remove unused "device" argument. (reinstall-bootloader, perform-action): Adapt callers.
2017-07-28bootloader: Use <menu-entry> for the bootloader side.Danny Milosavljevic
* gnu/bootloader.scm (menu-entry-device-mount-point): New variable. Export it. (<menu-entry>: New field "device". * gnu/bootloader/grub.scm (grub-confgiuration-file): Handle <menu-entry> entries. * gnu/bootloader/extlinux.scm (extlinux-configuration-file): Handle <menu-entry> entries. * gnu/system.scm (menu->entry->boot-parameters): Delete variable. (boot-parameters->menu-entry): New variable. Export it. (operating-system-bootcfg): Make OLD-ENTRIES a list of <menu-entry>. * guix/script/system.scm (reinstall-bootloader): Fix bootcfg usage. (perform-action): Fix bootcfg usage.
2017-07-18guix system: Use "image.iso" as the name of ISO images.Ludovic Courtès
* guix/scripts/system.scm (system-derivation-for-action): Pass #:name to 'system-disk-image'.
2017-07-03guix system: Add "--file-system-type" option.Danny Milosavljevic
* guix/scripts/system.scm (process-action): Pass file-system-type to ... (perform-action): ... here. Add new keyword argument. Pass new value to ... (system-derivation-for-action): ... here. Add new keyword argument. Pass new value to system-disk-image. * doc/guix.texi (disk-image): Document new option.
2017-06-30vm: Estimate the disk size by default.Ludovic Courtès
* gnu/build/vm.scm (estimated-partition-size): New procedure. * gnu/system/vm.scm (expression->derivation-in-linux-vm): Change #:disk-image-size default to 'guess. [builder]: When DISK-IMAGE-SIZE is 'guess, use 'estimated-partition-size' and compute and estimate of the image size. (qemu-image): Likewise. * guix/build/store-copy.scm (file-size, closure-size): New procedures. * guix/scripts/system.scm (%default-options): Change 'image-size' to 'guess. * doc/guix.texi (Building the Installation Image): Remove '--image-size' flag from example. (Invoking guix system): Document the image size estimate.
2017-06-10bootloader: Rename boot-name to bootloader-name.Mathieu Othacehe
* gnu/system (<boot-parameters>)[boot-name]: Rename field to... [bootloader-name]: ... this. Adjust users. * gnu/scripts/system.scm: Adjust accordingly.
2017-05-22Merge branch 'version-0.13.0'Marius Bakke
2017-05-21guix system: Don't warn about old distros for "guix system init".Ludovic Courtès
* guix/scripts/system.scm (process-action): Don't call 'warn-about-old-distro' when ACTION is 'init' or 'build'.
2017-05-21guix system: Increase image size for 'guix system vm'.Ludovic Courtès
This is a followup to 9a1bfe764859365b6726f168da95b88a2d22403b. * guix/scripts/system.scm (system-derivation-for-action): Add 40MiB to the default size for 'vm'.
2017-05-16scripts: system: Display bootloader name in "list-generations".Mathieu Othacehe
* guix/scripts/system.scm (display-system-generation): Display bootloader name.
2017-05-16scripts: system: Adapt "switch-generation" to new bootloader API.Mathieu Othacehe
* guix/scripts/system.scm (reinstall-grub): Rename to reinstall-bootloader. Read boot-device and boot-type from parameters file to be able to restore the correct bootloader on specified device. Factorize bootloader installation code by calling install-bootloader. (system-bootloader-name): New procedure. (switch-to-system-generation): Adapt.
2017-05-16scripts: system: Adapt "init" to new bootloader API.Mathieu Othacehe
* guix/scripts/system.scm (install): Pass installer a new argument. Rename other arguments. Call install-bootloader instead of install-grub*. (perform-action): Adapt.
2017-05-16scripts: system: Adapt "reconfigure" to new bootloader API.Mathieu Othacehe
* guix/scripts/system.scm (install-grub*): Rename to install-bootloader. Use keys to pass arguments. Pass a new argument, "installer-drv" which is a script in store dealing with bootloader-specific install actions. Also call "install-boot-config" to install the bootloader config file. (install-bootloader-derivation): New procedure. It returns a derivation that builds a file containing "install-procedure" gexp. (perform-action): Build install-proc derivation and call install-bootloader with the resulting file. Stop adding GRUB to PATH as bootloaders are called in install-proc with direct store paths.
2017-05-16bootloader: Add extlinux support.Mathieu Othacehe
* gnu/bootloader.scm: New file. * gnu/bootloader/extlinux.scm: New file. * gnu/bootloader/grub.scm: New file. * gnu/local.mk: Build new files. * gnu/system.scm: Adapt to new bootloader api. * gnu/scripts/system.scm: Adapt to new bootloader api. * gnu.scm: Remove (gnu system grub) and replace by (gnu bootloader) and (gnu bootloader grub) modules. * gnu/system/grub.scm: Moved content to gnu/bootloader/grub.scm. * gnu/system/vm: Replace (gnu system grub) module by (gnu bootloader). * gnu/tests.scm: Ditto. * gnu/tests/nfs.scm: Ditto.
2017-05-10scripts: Warn about old distro.Ludovic Courtès
Fixes <http://bugs.gnu.org/25852>. Suggested by Mark H Weaver <mhw@netris.org>. * guix/scripts.scm (%distro-age-warning): New variable. (warn-about-old-distro): New procedure. * guix/scripts/package.scm (process-actions): Call 'warn-about-old-distro'. * guix/scripts/system.scm (process-action): Likewise.
2017-05-05scripts: Remove profile-grub-entries.Danny Milosavljevic
* guix/scripts/system.scm (profile-grub-entries): Delete variable.
2017-05-05system: grub: Use boot-parameters instead of menu-entry where possible.Danny Milosavljevic
* gnu/system/grub.scm (boot-parameters->menu-entry): New variable. (grub-configuration-file): Use boot-parameters instead of menu-entry where possible. * guix/scripts/system.scm (profile-boot-parameters): Update docstring. (reinstall-grub): Use profile-boot-parameters. (perform-action): Use profile-boot-parameters.
2017-05-05scripts: Make boot-parameters label include generation number and time.Danny Milosavljevic
* guix/scripts/system.scm (system->boot-parameters): Make label include generation number and time.
2017-05-05system: Introduce read-boot-parameters-file.Danny Milosavljevic
* gnu/system.scm (read-boot-parameters): Remove export. (read-boot-parameters-file): New variable. Export it. * guix/scripts/system.scm (profile-boot-parameters): Use read-boot-parameters-file. (profile-grub-entries): Use read-boot-parameters-file. (reinstall-grub): Use read-boot-parameters-file. (display-system-generation): Use read-boot-parameters-file.
2017-05-03ui: Rename '_' to 'G_'.Ludovic Courtès
This avoids collisions with '_' when the latter is used as a 'match' pattern for instance. See <https://lists.gnu.org/archive/html/guix-devel/2017-04/msg00464.html>. * guix/ui.scm: Rename '_' to 'G_'. * po/guix/Makevars (XGETTEXT_OPTIONS): Adjust accordingly. * build-aux/compile-all.scm (warnings): Remove 'format'. * gnu/packages.scm, gnu/services.scm, gnu/services/shepherd.scm, gnu/system.scm, gnu/system/shadow.scm, guix/gnupg.scm, guix/http-client.scm, guix/import/cpan.scm, guix/import/elpa.scm, guix/import/pypi.scm, guix/nar.scm, guix/scripts.scm, guix/scripts/archive.scm, guix/scripts/authenticate.scm, guix/scripts/build.scm, guix/scripts/challenge.scm, guix/scripts/container.scm, guix/scripts/container/exec.scm, guix/scripts/copy.scm, guix/scripts/download.scm, guix/scripts/edit.scm, guix/scripts/environment.scm, guix/scripts/gc.scm, guix/scripts/graph.scm, guix/scripts/hash.scm, guix/scripts/import.scm, guix/scripts/import/cpan.scm, guix/scripts/import/cran.scm, guix/scripts/import/crate.scm, guix/scripts/import/elpa.scm, guix/scripts/import/gem.scm, guix/scripts/import/gnu.scm, guix/scripts/import/hackage.scm, guix/scripts/import/nix.scm, guix/scripts/import/pypi.scm, guix/scripts/import/stackage.scm, guix/scripts/lint.scm, guix/scripts/offload.scm, guix/scripts/pack.scm, guix/scripts/package.scm, guix/scripts/perform-download.scm, guix/scripts/publish.scm, guix/scripts/pull.scm, guix/scripts/refresh.scm, guix/scripts/size.scm, guix/scripts/substitute.scm, guix/scripts/system.scm, guix/ssh.scm, guix/upstream.scm: Use 'G_' instead of '_'. Most of this change was obtained by running: "sed -i -e's/(_ "/(G_ "/g' `find -name \*.scm`".
2017-04-17scripts: system: Rename --no-grub option to --no-bootloader.Mathieu Othacehe
* guix/scripts/system.scm (%options, show-help): Adjust accordingly. Keep "--no-grub" for compatibility reasons, but do not mention it in the help. Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
2017-04-16services: 'service-parameters' becomes 'service-value'.Ludovic Courtès
* gnu/services.scm (<service>)[parameters]: Rename to... [value]: ... this. Change calls to 'service-parameters' to 'service-value'. * gnu/system.scm, gnu/tests/base.scm, guix/scripts/system.scm, tests/services.scm: Likewise. * doc/guix.texi (Service Reference): Adjust accordingly.
2017-04-15system: Make grub use <menu-entry> instead of <boot-parameters> again.Danny Milosavljevic
* gnu/system/grub.scm: Remove boot-parameters->menu-entry. (grub-configuration): Don't use boot-parameters->menu-entry. * gnu/system.scm (operating-system-bootcfg): Use menu-entry. * guix/scripts/system.scm (reinstall-grub): Use profile-grub-entries. (perform-action): Use profile-grub-entries.
2017-04-15scripts: system: Introduce profile-boot-parameters.Danny Milosavljevic
* guix/scripts/system.scm (profile-boot-parameters): New variable. (reinstall-grub): Use profile-boot-parameters. (perform-action): Use profile-boot-parameters. Follow-up to 2e58e05bb68d4b747882cfa2b460b132d456f54a.
2017-04-15scripts: system: Rename grub? and install-grub? to bootloader? and ↵Mathieu Othacehe
install-bootloader?. * guix/scripts/system.scm (perform-action): Rename grub? to bootloader, (%options): rename install-grub? to install-bootloader?, (%default-options): ditto, (process-action): reindent and rename grub? to bootloader?.
2017-04-15system: Rename operating-system-grub.cfg to operating-system-bootcfg.Mathieu Othacehe
* gnu/system.scm (operating-system-grub.cfg): Rename to... (operating-system-bootcfg): ... this. * gnu/system/vm.scm (system-disk-image): Use operating-system-bootcfg. (system-qemu-image): Use operating-system-bootcfg. (system-qemu-image/shared-store): Use operating-system-bootcfg. * guix/scripts/system.scm (perform-action): Use operating-system-bootcfg. Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
2017-04-15scripts: system: Back out operating-system-bootcfg change.Danny Milosavljevic
Follow-up to 475e2ce211ac05a814c1f1bc2b9648baa17ad369. * guix/scripts/system.scm (perform-action): Back out operating-system-bootcfg change.
2017-04-15scripts: system: Move save-load-path-excursion and ↵Danny Milosavljevic
save-environment-excursion macros to the top. * guix/scripts/system.scm (save-load-path-excursion, save-environment-excursion): Move definitions to the top of the file. It allows to use them in the whole file. Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
2017-04-15scripts: system: Move save-load-path-excursion and ↵Mathieu Othacehe
save-environment-excursion macros to the top. * guix/scripts/system.scm (save-load-path-excursion, save-environment-excursion): Move definitions to the top of the file. It allows to use them in the whole file. Signed-off-by: Danny Milosavljevic <dannym@scratchpost.org>
2017-04-06system: Support the --root option in 'guix system'.Chris Marusich
Fixes <https://bugs.gnu.org/26271>. * guix/scripts/system.scm (perform-action): Add #:gc-root parameter and honor it. (show-help): Document the --root option. (%options): Add 'root'. (process-action): Pass 'root' option to perform-action as #:gc-root. * doc/guix.texi (Invoking guix system): Document '--root'. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2016-12-05guix system: If the new system generation already exists, overwrite it.Chris Marusich
Fixes <http://bugs.gnu.org/25100>. Before that, 'guix system reconfigure' would fail if the next generation already existed. * guix/scripts/system.scm (switch-to-system): Use 'switch-symlink' instead of 'symlink'. * doc/guix.texi (Using the Configuration System, Invoking guix system): Document the behavior. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
2016-11-19store: Add 'references*'.Ludovic Courtès
* guix/store.scm (references*): New procedure. * guix/profiles.scm (manifest-lookup-package)[references*]: Remove. * guix/scripts/system.scm (references*): Remove. * tests/gexp.scm ("gexp->file", "gexp->file + file-append") ("gexp->derivation", "gexp->derivation, cross-compilation") ("gexp->derivation, ungexp + ungexp-native") ("scheme-file", "text-file*", "mixed-text-file"): Remove 'references*' instead of (store-lift references).
2016-11-08system: Use grub from bootloader configuration.Marius Bakke
* gnu/system/grub.scm (gnu): Export grub-configuration-grub. * guix/scripts/system.scm (perform-action): Use it. (define-module): Don't import (gnu packages grub). Co-authored-by: Danny Milosavljevic <dannym@scratchpost.org>