mirror of
https://github.com/Websoft9/websoft9.git
synced 2025-02-03 01:28:39 +08:00
apphub update
This commit is contained in:
parent
5c74768fab
commit
bea8007239
13
.github/workflows/build_apphub.yml
vendored
13
.github/workflows/build_apphub.yml
vendored
@ -36,3 +36,16 @@ jobs:
|
|||||||
username: ${{ secrets.DOCKER_USERNAME }}
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
|
||||||
|
- name: Download redoc.standalone.js
|
||||||
|
run: wget -O apphub/apidocs/redoc.standalone.js https://cdn.redoc.ly/redoc/latest/bundles/redoc.standalone.js
|
||||||
|
|
||||||
|
- name: Run Docker container and get openapi.json
|
||||||
|
run: |
|
||||||
|
docker run -d --name apphub -p 8080:80 websoft9dev/apphub:${{ env.VERSION }}
|
||||||
|
sleep 10 # Wait for the container to start
|
||||||
|
wget -O apphub/apidocs/openapi.json http://localhost:8080/docs/openapi.json
|
||||||
|
docker stop apphub
|
||||||
|
|
||||||
|
- uses: stefanzweifel/git-auto-commit-action@v4
|
||||||
|
with:
|
||||||
|
commit_message: Upgrade apphub api docs
|
@ -1,4 +1,4 @@
|
|||||||
# modify time: 202310231530, you can modify here to trigger Docker Build action
|
# modify time: 202310241440, you can modify here to trigger Docker Build action
|
||||||
|
|
||||||
FROM python:3.10-bullseye AS buildstage
|
FROM python:3.10-bullseye AS buildstage
|
||||||
LABEL maintainer="Websoft9<help@websoft9.com>"
|
LABEL maintainer="Websoft9<help@websoft9.com>"
|
||||||
|
@ -43,10 +43,10 @@ fi
|
|||||||
|
|
||||||
create_apikey() {
|
create_apikey() {
|
||||||
# 容器第一次启动时,不管apikey是否为空,调用apphub genkey
|
# 容器第一次启动时,不管apikey是否为空,调用apphub genkey
|
||||||
if [ ! -f /websoft9/first_run ]; then
|
if [ ! -f /websoft9/apphub/src/config/first_run ]; then
|
||||||
echo "Create new apikey"
|
echo "Create new apikey"
|
||||||
apphub genkey
|
apphub genkey
|
||||||
touch /websoft9/first_run
|
touch /websoft9/apphub/src/config/first_run
|
||||||
fi
|
fi
|
||||||
# apphub getkey 为空时,创建新的apikey
|
# apphub getkey 为空时,创建新的apikey
|
||||||
if [ -z "$(apphub getkey)" ]; then
|
if [ -z "$(apphub getkey)" ]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user