Compare commits

...

10 Commits

Author SHA1 Message Date
chenwj113 f16457bef5 Update .gitlab-ci.yml 2023-02-16 14:04:16 +08:00
chenwj113 dd8712cd49 Update .gitlab-ci.yml 2023-02-16 14:02:26 +08:00
chenwj113 efefff5bfd Update .gitlab-ci.yml 2023-02-16 13:58:30 +08:00
chenwj113 6b2dce4811 Update .gitlab-ci.yml 2023-02-16 13:55:34 +08:00
chenwj113 4cf73561ea Update .gitlab-ci.yml 2023-02-16 13:54:29 +08:00
chenwj113 8bde10f424 Update .gitlab-ci.yml 2023-02-16 13:41:55 +08:00
chenwj113 287cdbf3ad Update requirements.txt 2023-02-16 10:19:37 +08:00
chenwj113 9314afa0fa Update requirements.txt 2023-02-16 10:06:07 +08:00
chenwj113 6559008288 更新ci/cd 2023-02-16 09:55:37 +08:00
chenwj113 9a55c82e1b 更新gitlab CI/CD 2023-02-16 09:54:13 +08:00
2 changed files with 6 additions and 9 deletions

View File

@ -4,7 +4,6 @@ variables:
LATEST_VERSION: latest
K8S_NS: default
DEPLOYMENT_NAME: fastapi-app-template
TAG: master
before_script:
- PATH=.:$PATH
@ -14,12 +13,12 @@ stages:
- build
- deploy
deploy-staging:dep:
build-staging:dep:
stage: build
only:
- master
tags:
- $TAG
- master
script:
- echo "===== start build =========="
- docker build -t ${IMAGE_NAME} .
@ -29,13 +28,12 @@ deploy-staging:dep:
deploy-staging:dep:
stage: deploy
only:
- master
tags:
- $TAG
- master
script:
- echo "===== start deploy =========="
- if [ "$(kubectl get deployment -n $K8S_NS | grep $DEPLOYMENT_NAME | awk '{print $1}')" ]; then
- echo $CI_COMMIT_BRANCH
- if [[ $CI_COMMIT_BRANCH == 'master' ]] && [[ "$(kubectl get deployment -n $K8S_NS | grep $DEPLOYMENT_NAME | awk '{print $1}')" ]]; then
- kubectl rollout restart deployment $DEPLOYMENT_NAME -n $K8S_NS
- fi
- echo "===== end deploy !!!!!======="

View File

@ -7,13 +7,12 @@ fastapi==0.89.1
fastapi-plugins==0.11.0
FastAPI-SQLAlchemy==0.2.1
pydantic==1.10.4
pydantic-sqlalchemy==0.0.9
# pydantic-sqlalchemy==0.0.9
python-multipart==0.0.5
pytest==7.2.1
requests==2.28.2
sqlacodegen==2.3.0
SQLAlchemy==2.0.1
starlette==0.23.1
uvicorn==0.20.0
PyJWT==2.6.0
passlib==1.7.4