2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-04-28 19:46:46 +00:00

Docker: Add parent directories if they do not exist

This commit is contained in:
Oliver Walters 2021-05-25 09:32:21 +10:00
parent 2d61e6fc5d
commit ff80c722fb
3 changed files with 6 additions and 5 deletions

View File

@ -41,9 +41,10 @@ LABEL org.label-schema.schema-version="1.0" \
# Create user account # Create user account
RUN addgroup -S inventreegroup && adduser -S inventree -G inventreegroup RUN addgroup -S inventreegroup && adduser -S inventree -G inventreegroup
WORKDIR ${INVENTREE_HOME} WORKDIR ${INVENTREE_HOME}
RUN mkdir ${INVENTREE_STATIC_ROOT} RUN mkdir -p ${INVENTREE_STATIC_ROOT}
# Install required system packages # Install required system packages
RUN apk add --no-cache git make bash \ RUN apk add --no-cache git make bash \

View File

@ -3,12 +3,12 @@
# Create required directory structure (if it does not already exist) # Create required directory structure (if it does not already exist)
if [[ ! -d "$INVENTREE_STATIC_ROOT" ]]; then if [[ ! -d "$INVENTREE_STATIC_ROOT" ]]; then
echo "Creating directory $INVENTREE_STATIC_ROOT" echo "Creating directory $INVENTREE_STATIC_ROOT"
mkdir $INVENTREE_STATIC_ROOT mkdir -p $INVENTREE_STATIC_ROOT
fi fi
if [[ ! -d "$INVENTREE_MEDIA_ROOT" ]]; then if [[ ! -d "$INVENTREE_MEDIA_ROOT" ]]; then
echo "Creating directory $INVENTREE_MEDIA_ROOT" echo "Creating directory $INVENTREE_MEDIA_ROOT"
mkdir $INVENTREE_MEDIA_ROOT mkdir -p $INVENTREE_MEDIA_ROOT
fi fi
# Check if "config.yaml" has been copied into the correct location # Check if "config.yaml" has been copied into the correct location

View File

@ -3,12 +3,12 @@
# Create required directory structure (if it does not already exist) # Create required directory structure (if it does not already exist)
if [[ ! -d "$INVENTREE_STATIC_ROOT" ]]; then if [[ ! -d "$INVENTREE_STATIC_ROOT" ]]; then
echo "Creating directory $INVENTREE_STATIC_ROOT" echo "Creating directory $INVENTREE_STATIC_ROOT"
mkdir $INVENTREE_STATIC_ROOT mkdir -p $INVENTREE_STATIC_ROOT
fi fi
if [[ ! -d "$INVENTREE_MEDIA_ROOT" ]]; then if [[ ! -d "$INVENTREE_MEDIA_ROOT" ]]; then
echo "Creating directory $INVENTREE_MEDIA_ROOT" echo "Creating directory $INVENTREE_MEDIA_ROOT"
mkdir $INVENTREE_MEDIA_ROOT mkdir -p $INVENTREE_MEDIA_ROOT
fi fi
# Check if "config.yaml" has been copied into the correct location # Check if "config.yaml" has been copied into the correct location