Skip to content

Commit

Permalink
Replace TLD
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike5535 committed Sep 14, 2024
1 parent 6622d38 commit 2c64118
Show file tree
Hide file tree
Showing 10 changed files with 23 additions and 23 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/binaries_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
script: |
cd /home/webapps/movie-gate.online/backend/2022_2_BugOverload
cd /home/webapps/movie-gate.ru/backend/2022_2_BugOverload
git checkout deploy_binaries
git pull
Expand All @@ -67,7 +67,7 @@ jobs:
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
source: "binaries/*"
target: /home/webapps/movie-gate.online/backend/2022_2_BugOverload/cmd/
target: /home/webapps/movie-gate.ru/backend/2022_2_BugOverload/cmd/
strip_components: 1

- name: Restart backend
Expand All @@ -77,7 +77,7 @@ jobs:
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
script: |
cd /home/webapps/movie-gate.online/backend/2022_2_BugOverload
cd /home/webapps/movie-gate.ru/backend/2022_2_BugOverload
chmod -R 755 cmd/
chown -R ${{ secrets.USERNAME }}:${{ secrets.USERNAME }} cmd/
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
script: |
cd /home/webapps/movie-gate.online/backend/2022_2_BugOverload
cd /home/webapps/movie-gate.ru/backend/2022_2_BugOverload
export AWS_REGION=${{ secrets.AWS_REGION }}
export AWS_PROFILE=${{ secrets.AWS_PROFILE }}
Expand Down Expand Up @@ -86,7 +86,7 @@ jobs:
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
script: |
cd /home/webapps/movie-gate.online/backend/2022_2_BugOverload
cd /home/webapps/movie-gate.ru/backend/2022_2_BugOverload
git checkout deploy
git pull
Expand All @@ -103,7 +103,7 @@ jobs:
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
source: "binaries/*"
target: /home/webapps/movie-gate.online/backend/2022_2_BugOverload/cmd/
target: /home/webapps/movie-gate.ru/backend/2022_2_BugOverload/cmd/
strip_components: 1

- name: Run backend
Expand All @@ -113,7 +113,7 @@ jobs:
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
script: |
cd /home/webapps/movie-gate.online/backend/2022_2_BugOverload
cd /home/webapps/movie-gate.ru/backend/2022_2_BugOverload
chmod -R 755 cmd/
chown -R ${{ secrets.USERNAME }}:${{ secrets.USERNAME }} cmd/
Expand Down
14 changes: 7 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ fill-db:
# Production BEGIN ----------------------------------------------------

prod-create-env:
sudo cp /etc/letsencrypt/live/movie-gate.online/fullchain.pem ./cmd/api/
sudo cp /etc/letsencrypt/live/movie-gate.online/privkey.pem ./cmd/api/
sudo cp /etc/letsencrypt/live/movie-gate.ru/fullchain.pem ./cmd/api/
sudo cp /etc/letsencrypt/live/movie-gate.ru/privkey.pem ./cmd/api/

prod-restart:
docker-compose -f docker-compose.production.yml restart warehouse
Expand Down Expand Up @@ -141,11 +141,11 @@ run-perf-tests:
# Debug END -----------------------------------------------------------

send-bin:
scp ./cmd/filldb/filldb_bin root@95.163.242.214:/home/webapps/movie-gate.online/backend/2022_2_BugOverload/cmd/filldb/filldb_bin
scp ./cmd/api/api_bin root@95.163.242.214:/home/webapps/movie-gate.online/backend/2022_2_BugOverload/cmd/api/api_bin
scp ./cmd/image/image_bin root@95.163.242.214:/home/webapps/movie-gate.online/backend/2022_2_BugOverload/cmd/image/image_bin
scp ./cmd/warehouse/warehouse_bin root@95.163.242.214:/home/webapps/movie-gate.online/backend/2022_2_BugOverload/cmd/warehouse/warehouse_bin
scp ./cmd/auth/auth_bin root@95.163.242.214:/home/webapps/movie-gate.online/backend/2022_2_BugOverload/cmd/auth/auth_bin
scp ./cmd/filldb/filldb_bin root@95.163.242.214:/home/webapps/movie-gate.ru/backend/2022_2_BugOverload/cmd/filldb/filldb_bin
scp ./cmd/api/api_bin root@95.163.242.214:/home/webapps/movie-gate.ru/backend/2022_2_BugOverload/cmd/api/api_bin
scp ./cmd/image/image_bin root@95.163.242.214:/home/webapps/movie-gate.ru/backend/2022_2_BugOverload/cmd/image/image_bin
scp ./cmd/warehouse/warehouse_bin root@95.163.242.214:/home/webapps/movie-gate.ru/backend/2022_2_BugOverload/cmd/warehouse/warehouse_bin
scp ./cmd/auth/auth_bin root@95.163.242.214:/home/webapps/movie-gate.ru/backend/2022_2_BugOverload/cmd/auth/auth_bin

# Debug END -----------------------------------------------------------

Expand Down
4 changes: 2 additions & 2 deletions Makefile_old
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,8 @@ prod-mode:
# infrastructure
# Example: make prod-deploy IMAGES=/home/andeo/Загрузки/images S3_ENDPOINT=http://localhost:4566
prod-create-env:
sudo cp /etc/letsencrypt/live/movie-gate.online/fullchain.pem ./cmd/api/
sudo cp /etc/letsencrypt/live/movie-gate.online/privkey.pem ./cmd/api/
sudo cp /etc/letsencrypt/live/movie-gate.ru/fullchain.pem ./cmd/api/
sudo cp /etc/letsencrypt/live/movie-gate.ru/privkey.pem ./cmd/api/

# Example: make prod-deploy IMAGES=/home/webapps/images S3_ENDPOINT=http://localhost:4566
prod-deploy:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ MovieGate - это агрегатор фильмов, сериалов, актё

[Демо](https://www.youtube.com/watch?v=MOiBZshB6GA)

[Деплой](http://movie-gate.online/)
[Деплой](http://movie-gate.ru/)

API [документация](https://app.swaggerhub.com/apis/BugOverload/API-Kino/1.0.0)

Expand Down
2 changes: 1 addition & 1 deletion cmd/api/configs/debug.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ work_timeout = 3 #seconds

[cors]
methods = ["POST", "GET", "PUT", "DELETE"]
urls = ["http://localhost:3000", "http://movie-gate.online"]
urls = ["http://localhost:3000", "http://movie-gate.ru"]
headers = ["Content-Type", "Content-Length", "X-Csrf-Token"]
credentials = true
debug = true
Expand Down
2 changes: 1 addition & 1 deletion cmd/api/configs/prod.toml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ work_timeout = 3 #seconds

[cors]
methods = ["POST", "GET", "PUT", "DELETE"]
urls = ["https://movie-gate.online", "http://localhost:8088", "https://localhost:8088", "http://localhost:3000", "https://localhost:3000"]
urls = ["https://movie-gate.ru", "http://localhost:8088", "https://localhost:8088", "http://localhost:3000", "https://localhost:3000"]
headers = ["Content-Type", "Content-Length", "X-Csrf-Token"]
credentials = true
debug = false
Expand Down
4 changes: 2 additions & 2 deletions cmd/api/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,10 @@ import (
// @license.name Apache 2.0
// @license.url http://www.apache.org/licenses/LICENSE-2.0.html

// @host movie-gate.online
// @host movie-gate.ru
// @BasePath /
// @termsOfService http://swagger.io/terms/
// @servers http://movie-gate.online
// @servers http://movie-gate.ru
func main() {
// Config
var configPath string
Expand Down
2 changes: 1 addition & 1 deletion monitoring/grafana/grafana.ini
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ protocol = http
http_port = 3000

# The public facing domain name used to access grafana from a browser
domain = movie-gate.online
domain = movie-gate.ru

# Redirect to correct domain if host header does not match domain
# Prevents DNS rebinding attacks
Expand Down
2 changes: 1 addition & 1 deletion monitoring/grafana/provisioning/dashboards/providers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: 1

providers:
- name: 'default'
folder: 'movie-gate.online'
folder: 'movie-gate.ru'
type: file
allowUiUpdates: true
updateIntervalSeconds: 30
Expand Down

0 comments on commit 2c64118

Please sign in to comment.