Stage 서버에 deploy 할 때 index.html 파일을 /var/www/html 폴더에 복사하는 내용 추가

This commit is contained in:
2026-07-06 22:25:34 +09:00
parent e17b1f0f1f
commit aeef3b63cb
2 changed files with 11 additions and 0 deletions
+7
View File
@@ -19,3 +19,10 @@ RUN { \
ENV TZ=Asia/Seoul ENV TZ=Asia/Seoul
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
RUN printf '#!/bin/sh\ncp /var/www/html/mouse_typing/index.html /var/www/html/index.html\nexec "$@"\n' \
> /usr/local/bin/entrypoint.sh \
&& chmod +x /usr/local/bin/entrypoint.sh
ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]
CMD ["apache2-foreground"]
+4
View File
@@ -19,5 +19,9 @@ fi
echo "=== [3/3] docker compose up ===" echo "=== [3/3] docker compose up ==="
docker compose -f $BASE_DIR/docker-compose.yml up -d docker compose -f $BASE_DIR/docker-compose.yml up -d
if [ $? -ne 0 ]; then
echo "docker compose up 실패. 배포 중단."
exit 1
fi
echo "=== 배포 완료 ===" echo "=== 배포 완료 ==="