User Tools

Site Tools


visiesrv2_lxc_containers

This is an old revision of the document!


LXC containers

The current defined containers are listed here. Note that the actual active container for visionlab website is visielab-test

NAME STATE IPV4 IPV6 TYPE SNAPSHOTS
nextcloud RUNNING 10.27.117.84 (eth0) PERSISTENT 6
openaudit RUNNING 10.27.117.9 (eth0) PERSISTENT 2
visielab STOPPED PERSISTENT 3
visielab-test RUNNING 10.27.117.155 (eth0) PERSISTENT 7
visielab-wiki RUNNING 10.27.117.55 (eth0) PERSISTENT 0

To do some testing on the visielab website, just make a snapshot, and then copy the snapshot. Then you can experiment on that copy after starting it. For example, visielab-test is currently the active visielab website. To test some special stuff on that website, we do the following.

#lxc snapshot visielab-test
#lxc info visielab-test
Name: visielab-test
Remote: unix://
Architecture: x86_64
Created: 2018/01/05 12:22 UTC
Status: Running
Type: persistent
Profiles: default
Pid: 14568
Ips:
  eth0: inet    10.27.117.155   vethQK0QJ3
  eth0: inet6   fe80::216:3eff:fe85:6ba6        vethQK0QJ3
  lo:   inet    127.0.0.1
  lo:   inet6   ::1
Resources:
  Processes: 83
  Disk usage:
    root: 10.10GB
  Memory usage:
    Memory (current): 847.15MB
    Memory (peak): 862.75MB
  Network usage:
    eth0:
      Bytes received: 316.82MB
      Bytes sent: 10.25GB
      Packets received: 1772073
      Packets sent: 1675147
    lo:
      Bytes received: 106.16kB
      Bytes sent: 106.16kB
      Packets received: 1100
      Packets sent: 1100
Snapshots:
  snap0 (taken at 2018/01/12 13:34 UTC) (stateless)
  snap1 (taken at 2018/01/26 14:44 UTC) (stateless)
  snap2 (taken at 2018/01/31 12:28 UTC) (stateless)
  snap3 (taken at 2018/02/23 12:21 UTC) (stateless)
  snap4 (taken at 2018/02/26 12:10 UTC) (stateless)
  snap5 (taken at 2018/03/30 13:52 UTC) (stateless)
  snap6 (taken at 2018/04/04 06:58 UTC) (stateless)

networking of the LXC containers

We defined all networking in /etc/lxd_bridge.conf .To use dnsmasq with this data, the correct variable must be defined in /etc/default/lxd-bridge → LXD_CONFILE=“/etc/lxd_bridge.conf”

cat lxd_bridge.conf 
domain=ac.ua.be
dhcp-host=nextcloud,10.27.117.84
dhcp-host=openaudit,10.27.117.9
dhcp-host=visielab,10.27.117.144
dhcp-host=visielab-test,10.27.117.155
dhcp-host=visielab-test2,10.27.117.250
dhcp-host=visielab-wiki,10.27.117.55

reverse proxying via apache

to address the different websites in the lxc containers, we use reverse proxying with apache2.

visiesrv2_lxc_containers.1522847629.txt.gz · Last modified: 2018/04/04 13:13 by jpe