Files
.infineon/_-Review/lxd.md
2024-11-06 12:39:13 -07:00

2.1 KiB

type, created, updated
type created updated
note 2024-06-27T02:58:25.205Z 2024-06-28T01:01:08.642Z

LXD

lxc profile list
lxc profile show default
lxc network list
lxc network show lxdbr0
lxc storage list
lxc storage show nixcraftzfs
# https://ubuntu.com/tutorials/how-to-run-docker-inside-lxd-containers#4-test-your-docker-container
# See bash with same date
sudo -i
snap install lxd
lxd init
config:
  core.https_address: '[::]:8443'
networks:
- config:
    ipv4.address: auto
    ipv6.address: none
  description: ""
  name: lxdbr0
  type: ""
  project: default
storage_pools:
- config:
    size: 30GiB
  description: ""
  name: default
  driver: btrfs
storage_volumes: []
profiles:
- config: {}
  description: ""
  devices:
    eth0:
      name: eth0
      network: lxdbr0
      type: nic
    root:
      path: /
      pool: default
      type: disk
  name: default
projects: []
cluster: null
lxc launch ubuntu:24.04 ubuntu-noble-test
lxc list
lxc exec ubuntu-noble-test bash
lxc config trust add /home/phares/lxd-ui-localhost.crt
# Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))
# choco install lxc virt-viewer
# https://virt-manager.org/download.html
lxc launch images:ubuntu/22.04/desktop vm-1 --vm -c limits.cpu=4 -c limits.memory=4GiB -c boot.autostart=true
lxc console vm-1 --type=vga
# https://discussion.scottibyte.com/t/self-hosted-totp-2fa-for-the-home/236
# https://lxdware.com/installing-the-lxd-dashboard-on-ubuntu-22-04/
lxc config set core.https_address :8443
lxc config trust add --name lxd-ui
snap restart --reload lxd
lxc config trust list