Add deploy step
continuous-integration/drone/push Build was killed
Details
continuous-integration/drone/push Build was killed
Details
parent
b407b94c0f
commit
15784560a9
54
.drone.yml
54
.drone.yml
|
@ -343,10 +343,56 @@ name: deploy
|
|||
clone:
|
||||
depth: 1
|
||||
steps:
|
||||
- name: nop
|
||||
image: 'alpine:3.8'
|
||||
commands:
|
||||
- echo nop
|
||||
- name: submodule
|
||||
image: plugins/git
|
||||
settings:
|
||||
recursive: true
|
||||
submodule_override:
|
||||
backend-auth: 'https://git.makerforce.io/beep/backend-auth.git'
|
||||
backend-bite: 'https://git.makerforce.io/beep/backend-bite.git'
|
||||
backend-core: 'https://git.makerforce.io/beep/backend-core.git'
|
||||
backend-heartbeat: 'https://git.makerforce.io/beep/backend-heartbeat.git'
|
||||
backend-login: 'https://git.makerforce.io/beep/backend-login.git'
|
||||
backend-protobuf: 'https://git.makerforce.io/beep/backend-protobuf.git'
|
||||
backend-publish: 'https://git.makerforce.io/beep/backend-publish.git'
|
||||
backend-signal: 'https://git.makerforce.io/beep/backend-signal.git'
|
||||
backend-store: 'https://git.makerforce.io/beep/backend-store.git'
|
||||
backend-subscribe: 'https://git.makerforce.io/beep/backend-subscribe.git'
|
||||
backend-transcription: 'https://git.makerforce.io/beep/backend-transcription.git'
|
||||
- name: copy-docker-compose
|
||||
image: appleboy/drone-scp
|
||||
settings:
|
||||
host: staging.beepvoice.app
|
||||
username: core
|
||||
ssh_key:
|
||||
from_secret: ssh_key
|
||||
source:
|
||||
- docker-compose.staging.yml
|
||||
target: /home/core/staging
|
||||
- name: copy-migrations
|
||||
image: appleboy/drone-scp
|
||||
settings:
|
||||
host: staging.beepvoice.app
|
||||
username: core
|
||||
ssh_key:
|
||||
from_secret: ssh_key
|
||||
source:
|
||||
- backend-core/postgres/*
|
||||
target: /home/core/staging/backend-core/postgres
|
||||
- name: docker-compose-up
|
||||
image: appleboy/drone-ssh
|
||||
settings:
|
||||
host: staging.beepvoice.app
|
||||
username: core
|
||||
ssh_key:
|
||||
from_secret: ssh_key
|
||||
script:
|
||||
- >-
|
||||
cd /home/core/staging && docker-compose -f docker-compose.staging.yml
|
||||
pull
|
||||
- >-
|
||||
cd /home/core/staging && docker-compose -f docker-compose.staging.yml
|
||||
up -d
|
||||
depends_on:
|
||||
- backend-auth
|
||||
- backend-bite
|
||||
|
|
|
@ -93,3 +93,6 @@ URL: `<base-url>/transcription`
|
|||
`transcription` takes the raw audio data, packages it and then sends it to the [Google Cloud Speech-to-Text](https://cloud.google.com/speech-to-text/). Sends the transcripted result to `store` to be stored. Handles HTTP requests to retrieve transcriptions too.
|
||||
|
||||
`transcription` relies on a running `nats` instance. Is insecure if not behind `traefik` calling `auth`.
|
||||
|
||||
## Staging
|
||||
|
||||
|
|
56
drone_gen.js
56
drone_gen.js
|
@ -59,11 +59,57 @@ const deploy = {
|
|||
},
|
||||
steps: [
|
||||
{
|
||||
name: 'nop',
|
||||
image: 'alpine:3.8',
|
||||
commands: [
|
||||
'echo nop',
|
||||
],
|
||||
name: 'submodule',
|
||||
image: 'plugins/git',
|
||||
settings: {
|
||||
recursive: true,
|
||||
submodule_override,
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'copy-docker-compose',
|
||||
image: 'appleboy/drone-scp',
|
||||
settings: {
|
||||
host: 'staging.beepvoice.app',
|
||||
username: 'core',
|
||||
ssh_key: {
|
||||
from_secret: 'ssh_key',
|
||||
},
|
||||
source: [
|
||||
'docker-compose.staging.yml',
|
||||
],
|
||||
target: '/home/core/staging',
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'copy-migrations',
|
||||
image: 'appleboy/drone-scp',
|
||||
settings: {
|
||||
host: 'staging.beepvoice.app',
|
||||
username: 'core',
|
||||
ssh_key: {
|
||||
from_secret: 'ssh_key',
|
||||
},
|
||||
source: [
|
||||
'backend-core/postgres/*',
|
||||
],
|
||||
target: '/home/core/staging/backend-core/postgres',
|
||||
},
|
||||
},
|
||||
{
|
||||
name: 'docker-compose-up',
|
||||
image: 'appleboy/drone-ssh',
|
||||
settings: {
|
||||
host: 'staging.beepvoice.app',
|
||||
username: 'core',
|
||||
ssh_key: {
|
||||
from_secret: 'ssh_key',
|
||||
},
|
||||
script: [
|
||||
'cd /home/core/staging && docker-compose -f docker-compose.staging.yml pull',
|
||||
'cd /home/core/staging && docker-compose -f docker-compose.staging.yml up -d',
|
||||
],
|
||||
},
|
||||
},
|
||||
],
|
||||
depends_on: dockers,
|
||||
|
|
Loading…
Reference in New Issue