From f85c91606962e9ddc6f91463763c0aade8fc9e1e Mon Sep 17 00:00:00 2001 From: CJ_Clippy Date: Sat, 11 Jan 2025 08:55:47 -0800 Subject: [PATCH] add make to bright alpine --- config/deploy.yml | 31 +++++++++++++++++++++++++------ docker-compose.yml | 3 ++- dockerfiles/bright.dockerfile | 2 +- 3 files changed, 28 insertions(+), 8 deletions(-) diff --git a/config/deploy.yml b/config/deploy.yml index 3104f7d..61752c3 100644 --- a/config/deploy.yml +++ b/config/deploy.yml @@ -10,11 +10,7 @@ image: futureporn/bright servers: web: - 45.76.57.101 - # - 127.0.0.1 - # job: - # hosts: - # - 192.168.0.1 - # cmd: bin/jobs + # Enable SSL auto certification via Let's Encrypt and allow for multiple apps on a single web server. # Remove this section when using multiple web servers and ensure you terminate SSL at your load balancer. @@ -23,6 +19,13 @@ servers: proxy: ssl: true host: bright.futureporn.net + healthcheck: + path: /up + interval: 2 + timeout: 2 + +# how long to wait for new containers to boot +deploy_timeout: 420 # Credentials for your image host. registry: @@ -82,10 +85,11 @@ ssh: # Use accessory services (secrets come from .kamal/secrets). # accessories: + db: image: postgres:15 host: 45.76.57.101 - port: 5432 + port: "127.0.0.1:5432:5432" env: clear: POSTGRES_USER: postgres @@ -94,6 +98,7 @@ accessories: - POSTGRES_PASSWORD directories: - pg_data:/var/lib/postgresql/data + redis: image: valkey/valkey:8 host: 45.76.57.101 @@ -101,3 +106,17 @@ accessories: directories: - data:/data + pgadmin: + image: dpage/pgadmin4 + host: 45.76.57.101 + port: 5050 + env: + clear: + PGADMIN_LISTEN_PORT: "5050" + secret: + - PGADMIN_DEFAULT_EMAIL + - PGADMIN_DEFAULT_PASSWORD + proxy: + host: pgadmin.futureporn.net + healthcheck: + path: /login \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index af4d967..33d8006 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -69,7 +69,7 @@ services: depends_on: - db volumes: - - ./services/bright:/app + - ./services/bright/lib:/app/lib develop: watch: - action: sync+restart @@ -78,6 +78,7 @@ services: db: image: postgres:15 + container_name: futureporn-db environment: POSTGRES_USER: postgres POSTGRES_PASSWORD: password diff --git a/dockerfiles/bright.dockerfile b/dockerfiles/bright.dockerfile index f3db271..09aed4e 100644 --- a/dockerfiles/bright.dockerfile +++ b/dockerfiles/bright.dockerfile @@ -24,7 +24,7 @@ FROM elixir:1.17.2-alpine AS dev -RUN apk add git inotify-tools \ +RUN apk add git make inotify-tools \ && mkdir /home/user \ && chown 1000.1000 /home/user