Skip to content
This repository has been archived by the owner on May 11, 2021. It is now read-only.

Commit

Permalink
fix: remove proxy and setup simple back mirror
Browse files Browse the repository at this point in the history
  • Loading branch information
igorkamyshev committed Apr 8, 2019
1 parent ae36297 commit 0a5cb56
Show file tree
Hide file tree
Showing 7 changed files with 4 additions and 107 deletions.
14 changes: 1 addition & 13 deletions .github/main.workflow
Original file line number Diff line number Diff line change
Expand Up @@ -63,12 +63,6 @@ action "Build front image" {
needs = ["Login to Docker"]
}

action "Build proxy image" {
uses = "actions/docker/cli@8cdf801b322af5f369e00d85e9cf3a7122f49108"
args = "build -t igorkamyshev/checkmoney-proxy -f Dockerfile-proxy ."
needs = ["Login to Docker"]
}

action "Push back image" {
uses = "actions/docker/cli@8cdf801b322af5f369e00d85e9cf3a7122f49108"
args = "push igorkamyshev/checkmoney-back"
Expand All @@ -81,15 +75,9 @@ action "Push front image" {
needs = ["Build front image"]
}

action "Push proxy image" {
uses = "actions/docker/cli@8cdf801b322af5f369e00d85e9cf3a7122f49108"
args = "push igorkamyshev/checkmoney-proxy"
needs = ["Build proxy image"]
}

action "Deploy on server" {
uses = "maddox/actions/ssh@master"
needs = ["Push front image", "Push back image", "Push proxy image"]
needs = ["Push front image", "Push back image"]
args = "cd /root/web/checkmoney && docker-compose pull && docker-compose down && docker-compose up -d && docker-compose run back yarn evolutions:run && docker image prune -f"
secrets = ["HOST", "USER", "PUBLIC_KEY", "PRIVATE_KEY"]
}
15 changes: 0 additions & 15 deletions Dockerfile-proxy

This file was deleted.

4 changes: 3 additions & 1 deletion back/src/addons/setupTelegram.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ export const setupTelegram = (app: INestApplication) => {
const bot = app.get(TelegramBot)
const config = app.get(Configuration)

if (config.isProd()) {
const isMirror = config.getBooleanOrElse('IS_MIRROR', false)

if (config.isProd() && !isMirror) {
app.use(
bot.getMiddleware(config.getStringOrElse('APP_SECRET', 'secret-path')),
)
Expand Down
12 changes: 0 additions & 12 deletions proxy/index.js

This file was deleted.

12 changes: 0 additions & 12 deletions proxy/package.json

This file was deleted.

13 changes: 0 additions & 13 deletions proxy/pm2.config.js

This file was deleted.

41 changes: 0 additions & 41 deletions proxy/yarn.lock

This file was deleted.

0 comments on commit 0a5cb56

Please sign in to comment.