mirror of
https://github.com/srid/nixos-config.git
synced 2026-01-11 02:32:37 +08:00
1.1 KiB
1.1 KiB
Workflows for my lxd/incus configuration.
To build the image,
nix run .#incus-image-container-import public-container
To launch a container using it,
incus launch srid/public-container --ephemeral test
public-container runs nginx serving Hello world, which can test if the container is working.
# Find the IP
❯ incus list
+------+---------+----------------------+-----------------------------------------------+-----------------------+-----------+
| NAME | STATE | IPV4 | IPV6 | TYPE | SNAPSHOTS |
+------+---------+----------------------+-----------------------------------------------+-----------------------+-----------+
| test | RUNNING | 10.162.27.156 (eth0) | fd42:ef6e:8271:3b9f:216:3eff:fea2:b8a6 (eth0) | CONTAINER (EPHEMERAL) | 0 |
+------+---------+----------------------+-----------------------------------------------+-----------------------+-----------+
# curl container's nginx
❯ curl 10.162.27.156
Hello World%