mirror of
https://github.com/craigerl/aprsd.git
synced 2024-11-17 13:51:54 -05:00
Update Dockerfile-dev to fix plugin permissions
This patch changes the user creation to include creating a home directory so the plugin install installs those plugins as a --user option.
This commit is contained in:
parent
2825cac446
commit
d8318f2ae2
@ -12,12 +12,11 @@ ENV PIP_DEFAULT_TIMEOUT=100 \
|
||||
# cache is useless in docker image, so disable to reduce image size
|
||||
PIP_NO_CACHE_DIR=1
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
RUN set -ex \
|
||||
# Create a non-root user
|
||||
&& addgroup --system --gid 1001 appgroup \
|
||||
&& adduser --system --uid 1001 --gid 1001 --no-create-home appuser \
|
||||
&& useradd --uid 1001 --gid 1001 -s /usr/bin/bash -m -d /app appuser \
|
||||
# Upgrade the package index and install security upgrades
|
||||
&& apt-get update \
|
||||
&& apt-get upgrade -y \
|
||||
@ -31,6 +30,7 @@ RUN set -ex \
|
||||
|
||||
### Final stage
|
||||
FROM build as final
|
||||
WORKDIR /app
|
||||
|
||||
RUN git clone -b $APRSD_BRANCH https://github.com/craigerl/aprsd
|
||||
RUN cd aprsd && pip install --no-cache-dir .
|
||||
|
@ -9,7 +9,7 @@ if [ ! -z "${APRSD_PLUGINS}" ]; then
|
||||
IFS=$OLDIFS
|
||||
# call your procedure/other scripts here below
|
||||
echo "Installing '$plugin'"
|
||||
pip3 install $plugin
|
||||
pip3 install --user $plugin
|
||||
done
|
||||
fi
|
||||
|
||||
|
@ -9,7 +9,7 @@ if [ ! -z "${APRSD_PLUGINS}" ]; then
|
||||
IFS=$OLDIFS
|
||||
# call your procedure/other scripts here below
|
||||
echo "Installing '$plugin'"
|
||||
pip3 install $plugin
|
||||
pip3 install --user $plugin
|
||||
done
|
||||
fi
|
||||
|
||||
|
@ -9,7 +9,7 @@ if [ ! -z "${APRSD_PLUGINS}" ]; then
|
||||
IFS=$OLDIFS
|
||||
# call your procedure/other scripts here below
|
||||
echo "Installing '$plugin'"
|
||||
pip3 install $plugin
|
||||
pip3 install --user $plugin
|
||||
done
|
||||
fi
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user