This commit is contained in:
qiaofeng1227 2023-10-12 10:47:22 +08:00
parent e438fbd7d4
commit 48a361b68a
4 changed files with 7 additions and 6 deletions

View file

@ -31,7 +31,7 @@ RUN apt update && apt install git jq iproute2 supervisor -y && \
echo "This folder stored the credentials of other services that integrated with apphub" > credentials/readme
RUN pip install --upgrade pip && pip install -r apphub/requirements.txt
#RUN cd apphub && pip install .
#RUN cd apphub && pip install -e ./apphub
# supervisor
COPY config/supervisord.conf /etc/supervisor/conf.d/supervisord.conf
RUN chmod +r /etc/supervisor/conf.d/supervisord.conf

View file

@ -1,3 +1,3 @@
FROM websoft9dev/apphub:0.0.5 as buildstage
RUN mkdir -p /websoft9/src
RUN mkdir -p /websoft9/apphub-dev
RUN sed -i 's/supervisorctl start apphub/supervisorctl start apphubdev/g' /entrypoint.sh

View file

@ -7,6 +7,6 @@ autostart=true
directory=/websoft9/apphub
[program:apphubdev]
command=/bin/bash -c '[ -z "$(ls -A /websoft9/src)" ] && cp -r /websoft9/apphub/* /websoft9/src && uvicorn src.main:app --reload --host 0.0.0.0 --port 8080 --log-level error'
command=/bin/bash -c '[ -z "$(ls -A /websoft9/apphub-dev)" ] && cp -r /websoft9/apphub/* /websoft9/apphub-dev && uvicorn src.main:app --reload --host 0.0.0.0 --port 8080 --log-level error'
autostart=true
directory=/websoft9/src
directory=/websoft9/apphub-dev

View file

@ -11,9 +11,10 @@ services:
- 9001-9999:8080
restart: always
volumes:
- /data/mysource:/websoft9/src
- /data/mysource:/websoft9/apphub-dev
- apphub_media:/websoft9/media
- apphub_logs:/websoft9/apphub/logs
- apphub_logs:/websoft9/apphub-dev/logs
- apphub_config:/websoft9/apphub-dev/src/config
depends_on:
- deployment
- git