LXC: set LXC_ENV_FOLDER=lxc/$(shell hostname)/

Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
This commit is contained in:
Markus Heiser 2020-03-23 18:05:46 +01:00
parent 103c542b37
commit baf1ffd1fa
4 changed files with 14 additions and 9 deletions

View File

@ -1077,6 +1077,11 @@ in_container() {
[[ -f /.lxcenv ]]
}
LXC_ENV_FOLDER=
if in_container; then
LXC_ENV_FOLDER="lxc/$(hostname)/"
fi
lxc_init_container() {
# Create a /.lxcenv file in the root folder. Call this once after container

View File

@ -9,7 +9,7 @@
# sudo make ./utils/makefile.lxc lxc-activate
# sudo make ./utils/makefile.lxc lxc-deactivate
LXC_ENV_FOLDER=/lxc-$(shell hostname)
LXC_ENV_FOLDER=lxc/$(shell hostname)/
lxc-help::
@echo 'LXC: running in container LXC_ENV_FOLDER=$(LXC_ENV_FOLDER)'

View File

@ -8,9 +8,9 @@ export PYTHONPATH := $(SITE_PYTHON):$$PYTHONPATH
export PY_ENV PYDIST PYBUILD
# folder where the python distribution takes place
PYDIST = ./dist$(LXC_ENV_FOLDER)
PYDIST = ./$(LXC_ENV_FOLDER)dist
# folder where the python intermediate build files take place
PYBUILD = ./build$(LXC_ENV_FOLDER)
PYBUILD = ./$(LXC_ENV_FOLDER)build
# python version to use
PY ?=3
PYTHON ?= python$(PY)
@ -28,7 +28,7 @@ TEST_FOLDER ?= ./tests
TEST ?= .
VTENV_OPTS ?=
PY_ENV = ./local$(LXC_ENV_FOLDER)/py$(PY)
PY_ENV = ./$(LXC_ENV_FOLDER)local/py$(PY)
PY_ENV_BIN = $(PY_ENV)/bin
PY_ENV_ACT = . $(PY_ENV_BIN)/activate

View File

@ -7,13 +7,13 @@ SPHINXOPTS ?=
SPHINXBUILD ?= $(PY_ENV_BIN)/sphinx-build
SPHINX_CONF ?= conf.py
DOCS_FOLDER = docs$(LXC_ENV_FOLDER)
DOCS_BUILD = build/docs$(LXC_ENV_FOLDER)
DOCS_DIST = dist/docs$(LXC_ENV_FOLDER)
DOCS_FOLDER = ./$(LXC_ENV_FOLDER)docs
DOCS_BUILD = ./$(LXC_ENV_FOLDER)build/docs
DOCS_DIST = ./$(LXC_ENV_FOLDER)dist/docs
GH_PAGES ?= gh-pages
BOOKS_FOLDER = docs$(LXC_ENV_FOLDER)
BOOKS_DIST = dist/books$(LXC_ENV_FOLDER)
BOOKS_FOLDER = ./$(LXC_ENV_FOLDER)docs
BOOKS_DIST = ./$(LXC_ENV_FOLDER)dist/books
ifeq ($(KBUILD_VERBOSE),1)
SPHINX_VERBOSE = "-v"