mirror of
https://codeberg.org/postscriptum/gemlog.git
synced 2026-02-18 22:12:40 +00:00
initial commit
This commit is contained in:
commit
259fee630b
127 changed files with 7811 additions and 0 deletions
40
public/en/lxc-usage-examples.gmi
Normal file
40
public/en/lxc-usage-examples.gmi
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
# LXC usage examples
|
||||
|
||||
## Install
|
||||
|
||||
``` bash
|
||||
apt install apparmor apparmor-utils debootstrap lxc-templates lxc
|
||||
```
|
||||
|
||||
## Create new container
|
||||
|
||||
``` bash
|
||||
lxc-create -t debian -n NAME
|
||||
```
|
||||
* optionally, set custom location: `-P /path/to/lxc` (default: `/var/lib/lxc`)
|
||||
|
||||
## Run
|
||||
|
||||
### Foreground (debug)
|
||||
|
||||
``` bash
|
||||
lxc-start -n NAME -F
|
||||
```
|
||||
|
||||
### Background
|
||||
|
||||
``` bash
|
||||
lxc-start -n NAME -d
|
||||
```
|
||||
|
||||
## Login
|
||||
|
||||
``` bash
|
||||
lxc-attach -n NAME
|
||||
```
|
||||
|
||||
## Stop
|
||||
|
||||
``` bash
|
||||
lxc-stop -n NAME
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue