Initial commit

This commit is contained in:
2025-03-03 01:16:50 +03:00
parent be888d68b2
commit 2bef3a7fe4
11 changed files with 175 additions and 0 deletions

29
.gitlab-ci.yml Executable file
View File

@@ -0,0 +1,29 @@
stages:
- test
- build
- deploy
variables:
DOCKER_REGISTRY: "registry.beaconborn.ru:5005"
DOCKER_IMAGE: "$CI_PROJECT_NAMESPACE/$CI_PROJECT_NAME"
DOCKER_TAG: "latest"
test:
stage: test
image: python:3.11-alpine
script:
- pip install -r requirements.txt
- pytest --maxfail=1 --disable-warnings -q
only:
- main
build:
stage: build
script:
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $DOCKER_REGISTRY
- docker build -t $DOCKER_REGISTRY/$DOCKER_IMAGE:$DOCKER_TAG .
- docker push $DOCKER_REGISTRY/$DOCKER_IMAGE:$DOCKER_TAG
only:
- main