kind: pipeline type: docker name: default steps: - name: test image: python:3.11-slim commands: - pip install --no-cache-dir -r requirements.txt - pip install pytest pytest-asyncio - pytest tests/ -v || true - name: deploy image: docker:cli environment: DOCKER_HOST: unix:///var/run/docker.sock commands: - docker build -t gptchat:latest . - docker stop gptchat || true - docker rm gptchat || true - docker run -d --name gptchat -p 8484:8484 --restart unless-stopped gptchat:latest when: branch: - main event: - push