Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
tips:lxd [2018/04/09 12:05] – [install] scipiotips:lxd [2019/11/19 19:12] (current) – [container] scipio
Line 128: Line 128:
 lxc list lxc list
 </code> </code>
 +
 +create custom image from local container
 +<code>
 +lxc publish local-container --alias mycustomimage
 +</code>
 +
 +create container from previous image
 +<code>
 +lxc launch mycustomimage newcontainer
 +</code>
 +
 +
  
 bash inside bash inside
Line 168: Line 180:
 lxc network show br0 lxc network show br0
 lxc network edit br0 lxc network edit br0
 +</code>
 +
 +static IP container
 +<code>
 +istance=c1
 +
 +lxc stop $instance
 +lxc network attach lxdbr0 $istance eth0 eth0
 +lxc config device set $istance eth0 ipv4.address 10.99.10.42
 +lxc start $istance
 </code> </code>
 ===== servers ===== ===== servers =====
Line 199: Line 221:
 <code bash> <code bash>
 NAME=x11test NAME=x11test
-lxc launch images:ubuntu/xenial/amd64 $NAME+lxc launch images:ubuntu/bionic/amd64 $NAME
 </code> </code>
  
Line 209: Line 231:
 </code> </code>
  
-set DISPLAY env to xorg server on host + 
-<code bash+<code> 
-lxc config set $NAME environment.DISPLAY <ip-of-host-lxdbr0-bridge>:0+NAME=nvidia-sdk-manager 
 +lxc config set $NAME environment.DISPLAY <ip-of-host-lxdbr0-bridge>:0 
 +lxc config set $NAME environment.DISPLAY :0 
 +lxc config device add $NAME X0 disk path=/tmp/.X11-unix/X0 source=/tmp/.X11-unix/X0 
 +lxc config device add $NAME Xauthority disk path=/root/.Xauthority source=${XAUTHORITY}
 </code> </code>
  
  • tips/lxd.1523268341.txt.gz
  • Last modified: 2018/04/09 12:05
  • by scipio