Skip to content

Latest commit

 

History

History
47 lines (37 loc) · 1.52 KB

container.md

File metadata and controls

47 lines (37 loc) · 1.52 KB

NixOS container

Create and start

Within the cloned liberaforms directory, run the following commands to create and then start the nixos-container

sudo nixos-container create liberaforms --flake ./#liberaforms
sudo nixos-container start liberaforms

The create command will output a local container IP address (such as 10.233.1.2). Once the container is started, visiting this address in a browser on the host system will display the LiberaForms instance where you can then follow the instructions on bootstrapping a first Admin user. The default admin email address is [email protected] though this can be easily modified in the flake.nix.

Login

This command can be used to login to a root shell for the container:

sudo nixos-container root-login liberaforms

Update

If you make changes to the flake.nix or the nix/module.nix and would like to see them reflected in an already running container, you can use the update command for this purpose:

sudo nixos-container update liberaforms --flake ./liberaforms

Stop and destroy

A container that has been started can be stopped, and one that has been created can be destroyed:

sudo nixos-container stop liberaforms
sudo nixos-container destroy liberaforms

Tests

The unit and functional test suite for LiberaForms can be run on NixOS using the command nix flake check.