1
0
mirror of https://github.com/avatao-content/test-tutorial-framework synced 2025-06-28 18:15:11 +00:00

Symlink webservice server.py to webide workdir

This commit is contained in:
Kristóf Tóth
2018-04-26 11:04:00 +02:00
parent b897ec449c
commit 1f1a1149c6
3 changed files with 7 additions and 7 deletions

View File

@ -2,7 +2,7 @@ FROM eu.gcr.io/avatao-challengestore/tutorial-framework
# Define variables to use later
ENV TFW_SERVER_DIR="/srv/.tfw" \
TFW_LOGIN_SERVICE_DIR="/srv/login_service" \
TFW_WEBSERVICE_DIR="/srv/login_service" \
TFW_IDE_WD="/home/${AVATAO_USER}/workdir" \
TFW_TERMINADO_WD="/home/${AVATAO_USER}/workdir"
@ -10,12 +10,12 @@ ENV TFW_SERVER_DIR="/srv/.tfw" \
COPY solvable/src ${TFW_SERVER_DIR}/
# Copy webservice to a dedicated directory
COPY solvable/src/webservice/ ${TFW_LOGIN_SERVICE_DIR}/
ADD solvable/src/webservice/frontend-deps.tar ${TFW_LOGIN_SERVICE_DIR}/static
COPY solvable/src/webservice/ ${TFW_WEBSERVICE_DIR}/
ADD solvable/src/webservice/frontend-deps.tar ${TFW_WEBSERVICE_DIR}/static
# Create IDE directory, add a file to it and give proper permissions to AVATAO_USER
# Create IDE directory, symlink server source and give proper permissions to AVATAO_USER
RUN mkdir -p ${TFW_IDE_WD} &&\
echo "This is a file in ${TFW_IDE_WD}" > ${TFW_IDE_WD}/text.txt &&\
ln -s ${TFW_WEBSERVICE_DIR}/server.py ${TFW_IDE_WD} &&\
chown -R ${AVATAO_USER}: ${TFW_IDE_WD} && chmod -R 755 ${TFW_IDE_WD}
# Hide TFW related code from user