Merge pull request 'Simplify admin pipeline to test deploy only' (#2) from develop into test
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
Reviewed-on: #2
This commit is contained in:
86
.drone.yml
86
.drone.yml
@@ -1,83 +1,27 @@
|
|||||||
---
|
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
type: docker
|
type: docker
|
||||||
name: ci-check
|
name: bogazici-admin
|
||||||
|
|
||||||
trigger:
|
trigger:
|
||||||
branch:
|
|
||||||
- develop
|
|
||||||
event:
|
event:
|
||||||
- push
|
- push
|
||||||
- pull_request
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: install
|
|
||||||
image: node:22-alpine
|
|
||||||
commands:
|
|
||||||
- npm ci
|
|
||||||
|
|
||||||
- name: typecheck
|
|
||||||
image: node:22-alpine
|
|
||||||
commands:
|
|
||||||
- npx tsc --noEmit
|
|
||||||
depends_on:
|
|
||||||
- install
|
|
||||||
|
|
||||||
- name: build
|
|
||||||
image: node:22-alpine
|
|
||||||
commands:
|
|
||||||
- npm run build
|
|
||||||
environment:
|
|
||||||
VITE_API_BASE_URL: https://api.test.bogazicidenizcilik.com
|
|
||||||
depends_on:
|
|
||||||
- install
|
|
||||||
|
|
||||||
---
|
|
||||||
kind: pipeline
|
|
||||||
type: ssh
|
|
||||||
name: deploy-test
|
|
||||||
|
|
||||||
trigger:
|
|
||||||
branch:
|
branch:
|
||||||
- test
|
- test
|
||||||
event:
|
|
||||||
- push
|
|
||||||
|
|
||||||
server:
|
|
||||||
host:
|
|
||||||
from_secret: server_host
|
|
||||||
user:
|
|
||||||
from_secret: server_user
|
|
||||||
ssh_key:
|
|
||||||
from_secret: server_ssh_key
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: deploy
|
- name: deploy-test-admin
|
||||||
commands:
|
image: appleboy/drone-ssh
|
||||||
|
when:
|
||||||
|
branch:
|
||||||
|
- test
|
||||||
|
settings:
|
||||||
|
host:
|
||||||
|
from_secret: SERVER_HOST
|
||||||
|
username:
|
||||||
|
from_secret: SERVER_USER
|
||||||
|
key:
|
||||||
|
from_secret: SERVER_SSH_KEY
|
||||||
|
port: 22
|
||||||
|
script:
|
||||||
- cd /opt/projects/bogazici/corporate-admin/test/admin
|
- cd /opt/projects/bogazici/corporate-admin/test/admin
|
||||||
- bash scripts/deploy-test.sh
|
- bash scripts/deploy-test.sh
|
||||||
|
|
||||||
---
|
|
||||||
kind: pipeline
|
|
||||||
type: ssh
|
|
||||||
name: deploy-prod
|
|
||||||
|
|
||||||
trigger:
|
|
||||||
branch:
|
|
||||||
- main
|
|
||||||
event:
|
|
||||||
- push
|
|
||||||
|
|
||||||
server:
|
|
||||||
host:
|
|
||||||
from_secret: server_host
|
|
||||||
user:
|
|
||||||
from_secret: server_user
|
|
||||||
ssh_key:
|
|
||||||
from_secret: server_ssh_key
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: deploy
|
|
||||||
commands:
|
|
||||||
- cd /opt/projects/bogazici/corporate-admin/prod/admin
|
|
||||||
- bash scripts/deploy-prod.sh
|
|
||||||
|
|||||||
Reference in New Issue
Block a user