mirror of
https://github.com/avatao-content/test-tutorial-framework
synced 2024-11-14 23:27:17 +00:00
Move TFW stuff to hidden location with proper permissions
This commit is contained in:
parent
709c61d130
commit
d6ff80230f
@ -93,7 +93,7 @@ run_test()
|
|||||||
{
|
{
|
||||||
cd "$TAO_PATH"
|
cd "$TAO_PATH"
|
||||||
mount_baseimage="-v ${BASEIMAGE_PATH}/lib/tfw:/usr/local/lib/tfw"
|
mount_baseimage="-v ${BASEIMAGE_PATH}/lib/tfw:/usr/local/lib/tfw"
|
||||||
mount_test="-v $TEST_PATH/solvable/src:/srv/app"
|
mount_test="-v $TEST_PATH/solvable/src:/srv/.tfw"
|
||||||
mount_volumes=""
|
mount_volumes=""
|
||||||
[ "${HOTRELOAD:-0}" == "1" ] && mount_volumes="${mount_baseimage} ${mount_test}"
|
[ "${HOTRELOAD:-0}" == "1" ] && mount_volumes="${mount_baseimage} ${mount_test}"
|
||||||
docker run --rm \
|
docker run --rm \
|
||||||
|
@ -1,17 +1,19 @@
|
|||||||
FROM eu.gcr.io/avatao-challengestore/tutorial-framework
|
FROM eu.gcr.io/avatao-challengestore/tutorial-framework
|
||||||
|
|
||||||
ENV TFW_APP_DIR="/srv/app" \
|
ENV TFW_SERVER_DIR="/srv/.tfw" \
|
||||||
TFW_LOGIN_APP_DIR="/tmp/source_code_server" \
|
TFW_LOGIN_APP_DIR="/tmp/source_code_server" \
|
||||||
TFW_WEBIDE_WD="/home/${AVATAO_USER}/workdir" \
|
TFW_WEBIDE_WD="/home/${AVATAO_USER}/workdir" \
|
||||||
TFW_TERMINADO_WD="/home/${AVATAO_USER}/workdir"
|
TFW_TERMINADO_WD="/home/${AVATAO_USER}/workdir"
|
||||||
|
|
||||||
COPY solvable/src ${TFW_APP_DIR}/
|
COPY solvable/src ${TFW_SERVER_DIR}/
|
||||||
COPY solvable/src/source_code_server/server.py ${TFW_LOGIN_APP_DIR}/
|
COPY solvable/src/source_code_server/server.py ${TFW_LOGIN_APP_DIR}/
|
||||||
COPY solvable/src/source_code_server/users.db ${TFW_LOGIN_APP_DIR}/
|
COPY solvable/src/source_code_server/users.db ${TFW_LOGIN_APP_DIR}/
|
||||||
COPY solvable/src/source_code_server/login_component.py ${TFW_WEBIDE_WD}/
|
COPY solvable/src/source_code_server/login_component.py ${TFW_WEBIDE_WD}/
|
||||||
|
|
||||||
RUN chown -R ${AVATAO_USER} ${TFW_WEBIDE_WD} &&\
|
RUN chown -R ${AVATAO_USER} ${TFW_WEBIDE_WD} &&\
|
||||||
chmod -R 755 ${TFW_WEBIDE_WD}
|
chmod -R 755 ${TFW_WEBIDE_WD} &&\
|
||||||
|
chown -R root ${TFW_SERVER_DIR} &&\
|
||||||
|
chmod -R 700 ${TFW_SERVER_DIR}
|
||||||
|
|
||||||
VOLUME ["/home/${AVATAO_USER}"]
|
VOLUME ["/home/${AVATAO_USER}"]
|
||||||
WORKDIR /home/${AVATAO_USER}
|
WORKDIR /home/${AVATAO_USER}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
[program:event_handler_main]
|
[program:event_handler_main]
|
||||||
user=root
|
user=root
|
||||||
directory=%(ENV_TFW_APP_DIR)s
|
directory=%(ENV_TFW_SERVER_DIR)s
|
||||||
command=python3 event_handler_main.py
|
command=python3 event_handler_main.py
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
[program:tfwserver]
|
[program:tfwserver]
|
||||||
user=root
|
user=root
|
||||||
directory=%(ENV_TFW_APP_DIR)s
|
directory=%(ENV_TFW_SERVER_DIR)s
|
||||||
command=python3 tfw_server.py
|
command=python3 tfw_server.py
|
Loading…
Reference in New Issue
Block a user