Files
plane/deploy/cli-install/docker-compose-caddy.yml

226 lines
6.9 KiB
YAML
Raw Permalink Normal View History

feat: Added Prime Monitor Go Service for monitoring, health check and feature flagging (#411) * feat: added build meta data to monitor * feat: added versioning to prime-monitor * feat: added logger package for prime-monitor * feat: implemented logging in cmd * feat: implemented moduled monorepo architecture * feat: added cron package for healthcheck * feat: added constants and modules for healthcheck * feat: added environment service getter method * feat: added environment service parser for parsing the recieved keys * feat: added environment service provider method * feat: added retry based executer for the test methods * feat: added http health check method and placeholders for redis & pg * feat: added tests for healthcheck methods * feat: added PerformHealthCheck Controller Method for execution of healthcheck controller * feat: added healthcheck test file for testing the healthcheck * feat: added healthcheck to work file * feat: added readme for healthcheck package * feat: created healthcheck register for prime scheduler * feat: added cron command for running cron subpart of monitor * feat: added prime schedule handler for cron * feat: added start command for starting up prime scheduler * feat: added build utility files for monitor * fix: goreleaser builds * feat: removed Redis method from healthcheck methods * feat: added docker file for building prime-monitor * feat: added flag for adding healthcheck duration for cron start * chore: removed redis as a healthcheck method * chore: modified actions to build monitor on branch build and docker images * feat: added monitor service in docker compose caddy * feat: added description for HealthCheckJob * fix: status code issue for reachable and non reachable * feat: added api package for connecting with prime api * feat: modified cmd package to report healthcheck status to prime * feat: added api types inside prime-monitor * feat: added message field for meta while status reporting * fix: modified constants for environment variables * feat: added monitor readme * fix: build-branch monitor content shift to build-branch-ee * chore: added build args on release * feat: remove version meta data from cli * fix: docker file changed to fix the build to default * fix: removed build flags from github branch build * fix: moved cron start to root level start cmd * fix: passed the recieved machine signature to api headers * feat: optimised docker build for monitor
2024-06-20 12:14:46 +05:30
x-monitor-env: &monitor-env
environment:
- SERVICE_HTTP_WEB=web:3000
- SERVICE_HTTP_API=api:8000
- SERVICE_HTTP_LIVE=live:3000
feat: Added Prime Monitor Go Service for monitoring, health check and feature flagging (#411) * feat: added build meta data to monitor * feat: added versioning to prime-monitor * feat: added logger package for prime-monitor * feat: implemented logging in cmd * feat: implemented moduled monorepo architecture * feat: added cron package for healthcheck * feat: added constants and modules for healthcheck * feat: added environment service getter method * feat: added environment service parser for parsing the recieved keys * feat: added environment service provider method * feat: added retry based executer for the test methods * feat: added http health check method and placeholders for redis & pg * feat: added tests for healthcheck methods * feat: added PerformHealthCheck Controller Method for execution of healthcheck controller * feat: added healthcheck test file for testing the healthcheck * feat: added healthcheck to work file * feat: added readme for healthcheck package * feat: created healthcheck register for prime scheduler * feat: added cron command for running cron subpart of monitor * feat: added prime schedule handler for cron * feat: added start command for starting up prime scheduler * feat: added build utility files for monitor * fix: goreleaser builds * feat: removed Redis method from healthcheck methods * feat: added docker file for building prime-monitor * feat: added flag for adding healthcheck duration for cron start * chore: removed redis as a healthcheck method * chore: modified actions to build monitor on branch build and docker images * feat: added monitor service in docker compose caddy * feat: added description for HealthCheckJob * fix: status code issue for reachable and non reachable * feat: added api package for connecting with prime api * feat: modified cmd package to report healthcheck status to prime * feat: added api types inside prime-monitor * feat: added message field for meta while status reporting * fix: modified constants for environment variables * feat: added monitor readme * fix: build-branch monitor content shift to build-branch-ee * chore: added build args on release * feat: remove version meta data from cli * fix: docker file changed to fix the build to default * fix: removed build flags from github branch build * fix: moved cron start to root level start cmd * fix: passed the recieved machine signature to api headers * feat: optimised docker build for monitor
2024-06-20 12:14:46 +05:30
- SERVICE_HTTP_PROXY=proxy:80
- SERVICE_HTTP_MINIO=plane-minio:9090
- SERVICE_TCP_REDIS=plane-redis:6379
- SERVICE_TCP_POSTGRES=plane-db:5432
- TRUSTED_PROXIES=${TRUSTED_PROXIES:-0.0.0.0/0}
feat: Added Prime Monitor Go Service for monitoring, health check and feature flagging (#411) * feat: added build meta data to monitor * feat: added versioning to prime-monitor * feat: added logger package for prime-monitor * feat: implemented logging in cmd * feat: implemented moduled monorepo architecture * feat: added cron package for healthcheck * feat: added constants and modules for healthcheck * feat: added environment service getter method * feat: added environment service parser for parsing the recieved keys * feat: added environment service provider method * feat: added retry based executer for the test methods * feat: added http health check method and placeholders for redis & pg * feat: added tests for healthcheck methods * feat: added PerformHealthCheck Controller Method for execution of healthcheck controller * feat: added healthcheck test file for testing the healthcheck * feat: added healthcheck to work file * feat: added readme for healthcheck package * feat: created healthcheck register for prime scheduler * feat: added cron command for running cron subpart of monitor * feat: added prime schedule handler for cron * feat: added start command for starting up prime scheduler * feat: added build utility files for monitor * fix: goreleaser builds * feat: removed Redis method from healthcheck methods * feat: added docker file for building prime-monitor * feat: added flag for adding healthcheck duration for cron start * chore: removed redis as a healthcheck method * chore: modified actions to build monitor on branch build and docker images * feat: added monitor service in docker compose caddy * feat: added description for HealthCheckJob * fix: status code issue for reachable and non reachable * feat: added api package for connecting with prime api * feat: modified cmd package to report healthcheck status to prime * feat: added api types inside prime-monitor * feat: added message field for meta while status reporting * fix: modified constants for environment variables * feat: added monitor readme * fix: build-branch monitor content shift to build-branch-ee * chore: added build args on release * feat: remove version meta data from cli * fix: docker file changed to fix the build to default * fix: removed build flags from github branch build * fix: moved cron start to root level start cmd * fix: passed the recieved machine signature to api headers * feat: optimised docker build for monitor
2024-06-20 12:14:46 +05:30
2024-04-26 18:18:31 +05:30
x-proxy-env: &proxy-env
2024-04-26 17:41:25 +05:30
environment:
- SITE_ADDRESS=${SITE_ADDRESS:-localhost:80}
- CERT_EMAIL=${CERT_EMAIL:-admin@example.com}
- CERT_ACME_CA=${CERT_ACME_CA:-}
2024-04-26 18:18:31 +05:30
- CERT_ACME_DNS=${CERT_ACME_DNS:-}
2024-04-26 17:41:25 +05:30
- BUCKET_NAME=${BUCKET_NAME:-uploads}
- FILE_SIZE_LIMIT=${FILE_SIZE_LIMIT:-5242880}
- LISTEN_HTTP_PORT=${LISTEN_HTTP_PORT:-80}
2024-05-17 11:23:15 +05:30
- LISTEN_HTTPS_PORT=${LISTEN_HTTPS_PORT:-443}
2024-04-26 17:41:25 +05:30
2024-04-26 18:18:31 +05:30
x-app-env: &app-env
2024-04-26 17:41:25 +05:30
environment:
- WEB_URL=${WEB_URL:-http://localhost}
- DEBUG=${DEBUG:-0}
- SENTRY_DSN=${SENTRY_DSN:-""}
- SENTRY_ENVIRONMENT=${SENTRY_ENVIRONMENT:-"production"}
- CORS_ALLOWED_ORIGINS=${CORS_ALLOWED_ORIGINS:-}
- API_BASE_URL=${API_BASE_URL:-http://api:8000}
2024-04-26 17:41:25 +05:30
# Gunicorn Workers
- GUNICORN_WORKERS=${GUNICORN_WORKERS:-2}
#DB SETTINGS
- PGHOST=${PGHOST:-plane-db}
- PGDATABASE=${PGDATABASE:-plane}
- POSTGRES_USER=${POSTGRES_USER:-plane}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD:-plane}
- POSTGRES_DB=${POSTGRES_DB:-plane}
- PGDATA=${PGDATA:-/var/lib/postgresql/data}
- DATABASE_URL=${DATABASE_URL:-postgresql://plane:plane@plane-db/plane}
# REDIS SETTINGS
- REDIS_HOST=${REDIS_HOST:-plane-redis}
- REDIS_PORT=${REDIS_PORT:-6379}
- REDIS_URL=${REDIS_URL:-redis://plane-redis:6379/}
# RabbitMQ Settings
- RABBITMQ_HOST=${RABBITMQ_HOST:-plane-mq}
- RABBITMQ_PORT=${RABBITMQ_PORT:-5672}
- RABBITMQ_DEFAULT_USER=${RABBITMQ_USER:-plane}
- RABBITMQ_DEFAULT_PASS=${RABBITMQ_PASSWORD:-plane}
- RABBITMQ_DEFAULT_VHOST=${RABBITMQ_VHOST:-plane}
- RABBITMQ_VHOST=${RABBITMQ_VHOST:-plane}
- AMQP_URL=${AMQP_URL:-amqp://plane:plane@plane-mq:5672/plane}
2024-04-26 17:41:25 +05:30
# Application secret
- SECRET_KEY=${SECRET_KEY:-60gp0byfz2dvffa45cxl20p1scy9xbpf6d8c5y0geejgkyp1b5}
# DATA STORE SETTINGS
- USE_MINIO=${USE_MINIO:-1}
- AWS_REGION=${AWS_REGION:-}
2024-04-26 17:41:25 +05:30
- AWS_ACCESS_KEY_ID=${AWS_ACCESS_KEY_ID:-"access-key"}
- AWS_SECRET_ACCESS_KEY=${AWS_SECRET_ACCESS_KEY:-"secret-key"}
- AWS_S3_ENDPOINT_URL=${AWS_S3_ENDPOINT_URL:-http://plane-minio:9000}
- AWS_S3_BUCKET_NAME=${AWS_S3_BUCKET_NAME:-uploads}
- MINIO_ROOT_USER=${MINIO_ROOT_USER:-"access-key"}
- MINIO_ROOT_PASSWORD=${MINIO_ROOT_PASSWORD:-"secret-key"}
- BUCKET_NAME=${BUCKET_NAME:-uploads}
- FILE_SIZE_LIMIT=${FILE_SIZE_LIMIT:-5242880}
dev: new license activation workflow for one and pro users (#739) * feat: added feature flag package for decrypting and refreshing the feature flags value * feat: added feature flagging route for route handlers * feat: added feature flag worker for managing and distributing feature flags * feat: implemented feature flag api implementation inside ff handler * feat: added exponential retry interval inside feature flagging * fix: route pattern of feature flag endpoint from monitor * feat: created endpoint to activate workspace from monitor * feat: made changes to accomodate db and activate endpoint * dev: update multi tenant environment settings * dev: workspace license activation flow * dev: update license activate endpoint * dev: update workspace license activate endpoint * feat: added feature flag user sync logic * feat: added constants and sync logic with private key inside * feat: added port as env variable * feat: added modification for removing license key in healthcheck * feat: example env pushed * fix: update monitor endpoints and license activation function * dev: initiate free workspace only for self hosted instances * dev: self hosting license endpoint updates * dev: remove monitor db * dev: update handlers * dev: self hosted license subscription web * dev: removed computed in self hosted subscription * fix: prime server url and delete old license while creating new license in sqlite * chore: subscription activation alert after successfull activation. * dev: update feature flag endpoints * fix: handled several cases of feature flags * fix: linting errors * dev: update monitor to handle workspace activation * dev: update decryption algorithm * feat: separated activation payload with the sync payload * dev: update feature flags endpoint * dev: change type for workspace sync * feat: added isActive flag for user activation * feat: removed creation of free users in monitor * feat: added method for workspace product * dev: add user email in types * feat: added method for workspace product * fix: uer license feature flag fetch * fix: handler fixed for feature key * chore: self managed license activation * chore: update validation license flow. * chore: license activation success. * dev: resync workspace license on activation * chore: plane one success modal. * feat: added constructs to inject private key build time * feat: updated the docker file with private key build argument * feat: added consumption od DEFAULT_PRIVATE_KEY when building monitor * dev: update private key --------- Co-authored-by: Henit Chobisa <chobisa.henit@gmail.com> Co-authored-by: gurusainath <gurusainath007@gmail.com> Co-authored-by: Prateek Shourya <prateekshourya29@gmail.com> Co-authored-by: sriram veeraghanta <veeraghanta.sriram@gmail.com>
2024-08-22 17:39:19 +05:30
- SSL_VERIFY=${SSL_VERIFY:-1}
- FEATURE_FLAG_SERVER_BASE_URL=${FEATURE_FLAG_SERVER_BASE_URL:-http://monitor:8080}
- PAYMENT_SERVER_BASE_URL=${PAYMENT_SERVER_BASE_URL:-http://monitor:8080}
2024-04-26 17:41:25 +05:30
x-live-env: &live-env
environment:
- API_BASE_URL=${API_BASE_URL:-http://api:8000}
- REDIS_HOST=${REDIS_HOST:-plane-redis}
- REDIS_PORT=${REDIS_PORT:-6379}
- REDIS_URL=${REDIS_URL:-redis://plane-redis:6379/}
2024-04-26 17:41:25 +05:30
services:
2024-05-09 16:45:52 +05:30
admin:
<<: *app-env
image: registry.plane.tools/plane/admin-enterprise:${APP_RELEASE_VERSION}
restart: unless-stopped
2024-05-22 12:58:26 +05:30
command: node admin/server.js admin
2024-05-09 16:45:52 +05:30
deploy:
replicas: ${ADMIN_REPLICAS:-1}
depends_on:
- api
- web
2024-04-26 17:41:25 +05:30
web:
<<: *app-env
image: registry.plane.tools/plane/web-enterprise:${APP_RELEASE_VERSION}
2024-04-26 17:41:25 +05:30
restart: unless-stopped
command: node web/server.js web
2024-04-26 17:41:25 +05:30
deploy:
replicas: ${WEB_REPLICAS:-1}
depends_on:
- api
- worker
space:
<<: *app-env
image: registry.plane.tools/plane/space-enterprise:${APP_RELEASE_VERSION}
2024-04-26 17:41:25 +05:30
restart: unless-stopped
command: node space/server.js space
2024-04-26 17:41:25 +05:30
deploy:
replicas: ${SPACE_REPLICAS:-1}
depends_on:
- api
- web
live:
<<: *live-env
image: registry.plane.tools/plane/live-enterprise:${APP_RELEASE_VERSION}
restart: unless-stopped
command: node live/dist/server.js live
deploy:
replicas: ${LIVE_REPLICAS:-1}
depends_on:
- api
- web
monitor:
<<: *monitor-env
image: registry.plane.tools/plane/monitor-enterprise:${APP_RELEASE_VERSION}
restart: on-failure:5
volumes:
- ${INSTALL_DIR}/data/monitor:/app
2024-04-26 17:41:25 +05:30
api:
<<: *app-env
image: registry.plane.tools/plane/backend-enterprise:${APP_RELEASE_VERSION}
2024-04-26 17:41:25 +05:30
restart: unless-stopped
2024-05-22 15:04:19 +05:30
command: ./bin/docker-entrypoint-api-ee.sh
2024-04-26 17:41:25 +05:30
deploy:
replicas: ${API_REPLICAS:-1}
volumes:
- ${INSTALL_DIR}/logs/api:/code/plane/logs
2024-04-26 17:41:25 +05:30
depends_on:
- plane-db
- plane-redis
worker:
<<: *app-env
image: registry.plane.tools/plane/backend-enterprise:${APP_RELEASE_VERSION}
2024-04-26 17:41:25 +05:30
restart: unless-stopped
2024-05-22 12:58:26 +05:30
command: ./bin/docker-entrypoint-worker.sh
volumes:
- ${INSTALL_DIR}/logs/worker:/code/plane/logs
2024-04-26 17:41:25 +05:30
depends_on:
- api
- plane-db
- plane-redis
beat-worker:
<<: *app-env
image: registry.plane.tools/plane/backend-enterprise:${APP_RELEASE_VERSION}
2024-04-26 17:41:25 +05:30
restart: unless-stopped
2024-05-22 12:58:26 +05:30
command: ./bin/docker-entrypoint-beat.sh
volumes:
- ${INSTALL_DIR}/logs/beat-worker:/code/plane/logs
2024-04-26 17:41:25 +05:30
depends_on:
- api
- plane-db
- plane-redis
migrator:
<<: *app-env
image: registry.plane.tools/plane/backend-enterprise:${APP_RELEASE_VERSION}
restart: "no"
2024-05-22 12:58:26 +05:30
command: ./bin/docker-entrypoint-migrator.sh
volumes:
- ${INSTALL_DIR}/logs/migrator:/code/plane/logs
2024-04-26 17:41:25 +05:30
depends_on:
- plane-db
- plane-redis
plane-db:
<<: *app-env
image: registry.plane.tools/plane/postgres:15.5-alpine
2024-04-26 17:41:25 +05:30
restart: unless-stopped
command: postgres -c 'max_connections=1000'
volumes:
- ${INSTALL_DIR}/data/db:/var/lib/postgresql/data
2024-04-26 18:18:31 +05:30
2024-04-26 17:41:25 +05:30
plane-redis:
<<: *app-env
image: registry.plane.tools/plane/valkey:7.2.5-alpine
2024-04-26 17:41:25 +05:30
restart: unless-stopped
volumes:
- ${INSTALL_DIR}/data/redis:/data
plane-mq:
<<: *app-env
image: registry.plane.tools/plane/rabbitmq:3.13.6-management-alpine
restart: unless-stopped
volumes:
- ${INSTALL_DIR}/data/mq:/var/lib/rabbitmq
2024-04-26 17:41:25 +05:30
plane-minio:
<<: *app-env
image: registry.plane.tools/plane/minio:latest
2024-04-26 17:41:25 +05:30
restart: unless-stopped
command: server /export --console-address ":9090"
volumes:
- ${INSTALL_DIR}/data/minio/uploads:/export
- ${INSTALL_DIR}/data/minio/data:/data
# Comment this if you already have a reverse proxy running
proxy:
<<: *proxy-env
image: registry.plane.tools/plane/caddy:latest
2024-04-26 17:41:25 +05:30
restart: unless-stopped
ports:
- ${LISTEN_HTTP_PORT:-80}:${LISTEN_HTTP_PORT:-80}
2024-05-17 11:23:15 +05:30
- ${LISTEN_HTTPS_PORT:-443}:${LISTEN_HTTPS_PORT:-443}
2024-04-26 17:41:25 +05:30
volumes:
- ${INSTALL_DIR}/Caddyfile:/etc/caddy/Caddyfile
- ${INSTALL_DIR}/caddy/config:/config
- ${INSTALL_DIR}/caddy/data:/data
depends_on:
- web
- api
- space
- admin
- live