Skip to content

Commit

Permalink
fix: missing trailing slash for source diretory in rsync
Browse files Browse the repository at this point in the history
  • Loading branch information
aldy505 committed May 18, 2024
1 parent 0b255b8 commit 51325c9
Show file tree
Hide file tree
Showing 6 changed files with 67 additions and 3 deletions.
10 changes: 10 additions & 0 deletions relay/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
relay:
mode: proxy
upstream: https://sentry.teknologiumum.com
host: 0.0.0.0
port: 3000

spool:
envelopes:
path: /work/relay-spool
max_disk_size: 1GB
52 changes: 52 additions & 0 deletions relay/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
services:
relay:
image: getsentry/relay:latest
command: run --config /
labels:
- "traefik.enable=true"
- "traefik.docker.network=public-web"
- "traefik.http.routers.relay.entrypoints=web,websecure"
- "traefik.http.routers.relay.rule=Host(`sin.sentry.teknologiumum.com`)"
- "traefik.http.routers.relay.tls.certresolver=tlsresolver"
- "traefik.http.routers.relay.middlewares=relay-header,relay-rate,relay-redirectscheme"
- "traefik.http.services.relay.loadbalancer.server.port=3000"
- "traefik.http.services.relay.loadbalancer.server.scheme=http"
- "traefik.http.services.relay.loadbalancer.healthcheck.interval=30s"
- "traefik.http.services.relay.loadbalancer.healthcheck.path=/api/relay/healthcheck/ready/"
- "traefik.http.middlewares.relay-rate.ratelimit.average=200"
- "traefik.http.middlewares.relay-rate.ratelimit.burst=300"
- "traefik.http.middlewares.relay-rate.ratelimit.period=1s"
- "traefik.http.middlewares.relay-header.headers.addvaryheader=true"
- "traefik.http.middlewares.relay-header.headers.frameDeny=true"
- "traefik.http.middlewares.relay-header.headers.browserxssfilter=true"
- "traefik.http.middlewares.relay-header.headers.stsSeconds=604800"
- "traefik.http.middlewares.relay-header.headers.stsIncludeSubdomains=true"
- "traefik.http.middlewares.relay-header.headers.browserXssFilter=true"
- "traefik.http.middlewares.relay-header.headers.contentTypeNosniff=true"
- "traefik.http.middlewares.relay-header.headers.customResponseHeaders.server=Teknologi Umum"
- "traefik.http.middlewares.relay-redirectscheme.redirectscheme.scheme=https"
- "traefik.http.middlewares.relay-redirectscheme.redirectscheme.permanent=true"
- "com.centurylinklabs.watchtower.enable=true"
platform: linux/amd64
deploy:
mode: replicated
replicas: 1
restart_policy:
condition: unless-stopped
delay: 30s
window: 120s
resources:
limits:
memory: 1GB
cpus: '2'
reservations:
memory: 10M
cpus: '0.05'
networks:
- public-web
volumes:
- ./config.yml:/config.yml

networks:
public-web:
external: true
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ def ping(host: str) -> bool:
for container in containers:
# Copy directory to destination
subprocess.call(
f"rsync -avz --progress {container} {server}:{container}".split(" "),
f"rsync -avrz --progress {container}/ {server}:{container}".split(" "),
stdout=sys.stdout,
stderr=sys.stderr,
)
Expand Down
1 change: 0 additions & 1 deletion traefik/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ services:
resources:
limits:
memory: 4GB
cpus: "4"
reservations:
memory: 100MB
cpus: "0.10"
Expand Down
2 changes: 1 addition & 1 deletion traefik/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

docker network create public-web -d bridge --subnet 172.31.0.0/22

docker network craete monitoring
docker network create monitoring
3 changes: 3 additions & 0 deletions uptime-kuma/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ services:
image: louislam/uptime-kuma:1
labels:
- "traefik.enable=true"
- "traefik.docker.network=public-web"
- "traefik.http.routers.uptime-kuma.entrypoints=web,websecure"
- "traefik.http.routers.uptime-kuma.rule=Host(`status.teknologiumum.com`)"
- "traefik.http.routers.uptime-kuma.tls.certresolver=tlsresolver"
Expand Down Expand Up @@ -37,6 +38,8 @@ services:
options:
max-size: 10M
max-file: 3
networks:
- public-web

volumes:
uptime-data:
Expand Down

0 comments on commit 51325c9

Please sign in to comment.