5 Commits

Author SHA1 Message Date
7388962a7d Merge branch 'codex/hosting-drone-setup'
Some checks failed
continuous-integration/drone/push Build was killed
2026-03-18 19:14:09 +07:00
7c54c57633 trying to merge this file 2026-03-18 19:12:13 +07:00
05b8efd0f2 Prepare hosting deployment and Drone image builds
Some checks failed
continuous-integration/drone/push Build was killed
continuous-integration/drone/pr Build was killed
2026-03-18 15:26:18 +06:00
fd84094aa4 Another attempt to fix .drone.yml...
Some checks failed
continuous-integration/drone/push Build is failing
2026-01-22 10:37:05 +07:00
7eb2ea5662 An attempt to fix .drone.yml, deleted python-security stage
Some checks failed
continuous-integration/drone/push Build encountered an error
2026-01-22 10:32:21 +07:00

View File

@@ -4,6 +4,7 @@ name: code-quality
trigger: trigger:
event: event:
- push
- pull_request - pull_request
steps: steps:
@@ -11,6 +12,7 @@ steps:
image: python:3.11-slim image: python:3.11-slim
commands: commands:
- cd backend - cd backend
- pip install --no-cache-dir -r requirements.txt
- python -m py_compile main.py auth.py daemons.py oidc_config.py - python -m py_compile main.py auth.py daemons.py oidc_config.py
- name: frontend-build-check - name: frontend-build-check
@@ -19,6 +21,14 @@ steps:
- cd frontend - cd frontend
- npm ci --silent - npm ci --silent
- npm run build - npm run build
- npm run lint || echo "ESLint warnings found"
- name: frontend-security
image: node:20-alpine
commands:
- cd frontend
- npm ci --silent
- npm audit --audit-level=moderate || echo "Security warnings found"
--- ---
kind: pipeline kind: pipeline
@@ -34,17 +44,20 @@ trigger:
- push - push
- tag - tag
depends_on:
- code-quality
steps: steps:
- name: build-backend-image - name: build-backend-image
image: plugins/docker image: plugins/docker
settings: settings:
registry: registry.nevetime.ru registry: registry.nevetime.ru
repo: registry.nevetime.ru/mc-panel-backend repo: registry.nevetime.ru/mc-panel-backend
cache_from:
- registry.nevetime.ru/mc-panel-backend:latest
tags: tags:
- latest - latest
- ${DRONE_BUILD_NUMBER} - "${DRONE_BUILD_NUMBER}"
- "${DRONE_COMMIT_SHA:0:8}"
- "${DRONE_BRANCH}"
auto_tag: true auto_tag: true
dockerfile: backend/Dockerfile dockerfile: backend/Dockerfile
context: backend context: backend
@@ -58,11 +71,11 @@ steps:
settings: settings:
registry: registry.nevetime.ru registry: registry.nevetime.ru
repo: registry.nevetime.ru/mc-panel-frontend repo: registry.nevetime.ru/mc-panel-frontend
cache_from:
- registry.nevetime.ru/mc-panel-frontend:latest
tags: tags:
- latest - latest
- ${DRONE_BUILD_NUMBER} - "${DRONE_BUILD_NUMBER}"
- "${DRONE_COMMIT_SHA:0:8}"
- "${DRONE_BRANCH}"
auto_tag: true auto_tag: true
dockerfile: frontend/Dockerfile dockerfile: frontend/Dockerfile
context: frontend context: frontend
@@ -70,3 +83,54 @@ steps:
from_secret: docker_username from_secret: docker_username
password: password:
from_secret: docker_password from_secret: docker_password
build_args:
- BUILD_DATE=${DRONE_BUILD_CREATED}
- VCS_REF=${DRONE_COMMIT_SHA}
- VERSION=${DRONE_TAG:-${DRONE_BRANCH}}
when:
event:
- push
- tag
---
kind: pipeline
type: docker
name: build-monolith
trigger:
branch:
- main
- master
- develop
event:
- push
- tag
depends_on:
- code-quality
steps:
- name: build-monolith-image
image: plugins/docker
settings:
registry: registry.nevetime.ru
repo: registry.nevetime.ru/mc-panel
tags:
- latest
- "${DRONE_COMMIT_SHA:0:8}"
- "${DRONE_BRANCH}"
auto_tag: true
dockerfile: Dockerfile
context: .
username:
from_secret: docker_username
password:
from_secret: docker_password
build_args:
- BUILD_DATE=${DRONE_BUILD_CREATED}
- VCS_REF=${DRONE_COMMIT_SHA}
- VERSION=${DRONE_TAG:-${DRONE_BRANCH}}
when:
event:
- push
- tag