Skip to content

Latest commit

 

History

History
60 lines (39 loc) · 1007 Bytes

DEV.md

File metadata and controls

60 lines (39 loc) · 1007 Bytes

incus local containers

please replace CONTAINER, TYPE and <ip> accordingly

launch container:

incus launch images:nixos/unstable r3CONTAINER -c security.privileged=true -c security.nesting=true

open shell inside container:

incus exec r3CONTAINER bash

deploy from local repo

setup

add keys:

container:

nix run --extra-experimental-features 'nix-command flakes' nixpkgs#ssh-import-id gh:YOURGHUSERNAME # add your github key for ssh
ip a # get ip

use

local:

nixos-rebuild --flake .#TYPE --target-host root@<ip> switch -L -v

deploy from inside container

setup

local:

incus config device add r3website nixr3 disk path=/etc/nixos source=$PWD

container:

nix --extra-experimental-features 'nix-command flakes' shell nixpkgs#git
git config --global --add safe.directory /etc/nixos
git config --global --add safe.directory /etc/nixos/.git

use

nixos-rebuild switch --flake /etc/nixos#TYPE