From aa619516706d530f3159df0c5d6d0efde3fe7d6a Mon Sep 17 00:00:00 2001 From: Chris Anderson Date: Thu, 13 Apr 2023 20:44:54 -0500 Subject: [PATCH] Improves documentation and compose file (#127) --- .env.example | 7 ++++--- README.md | 2 +- apps/platform/src/app.ts | 2 ++ docker-compose.yml | 8 +++++--- docs/docs/deploy/aws-ec2.md | 6 ++++-- docs/docs/overview/quick-start.md | 2 +- 6 files changed, 17 insertions(+), 10 deletions(-) diff --git a/.env.example b/.env.example index ce7e5de9..2f4185c5 100644 --- a/.env.example +++ b/.env.example @@ -1,16 +1,17 @@ APP_SECRET=Ck7Rt1uiy5WGbrTFj1HBjymbBoA6zqih BASE_URL=http://localhost:3000 UI_PORT=3000 +API_BASE_URL=http://localhost:3000/api DB_CLIENT=mysql2 -DB_HOST=127.0.0.1 -DB_USERNAME=parcelvoy +DB_HOST=mysql +DB_USERNAME=root DB_PASSWORD=parcelvoypassword DB_PORT=3306 DB_DATABASE=parcelvoy QUEUE_DRIVER=redis -REDIS_HOST=127.0.0.1 +REDIS_HOST=redis REDIS_PORT=6379 STORAGE_DRIVER=local diff --git a/README.md b/README.md index a53c8d53..ad106378 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ You can run Parcelvoy locally or in the cloud easily using Docker. To get up and running quickly to try things out, copy our latest `docker-compose.yml` and `.env` file onto your machine and go! ``` mkdir parcelvoy && cd parcelvoy -wget https://raw.githubusercontent.com/parcelvoy/parcelvoy/master/{.env.example,docker-compose.yml} +wget https://raw.githubusercontent.com/parcelvoy/platform/master/{.env.example,docker-compose.yml} mv .env.example .env docker compose up -d # run the Docker container ``` diff --git a/apps/platform/src/app.ts b/apps/platform/src/app.ts index 8cbb4cae..1977e4d3 100644 --- a/apps/platform/src/app.ts +++ b/apps/platform/src/app.ts @@ -23,6 +23,8 @@ export default class App { static async init(env: Env): Promise { + logger.info('parcelvoy initializing') + // Boot up error tracking const error = await loadError(env.error) diff --git a/docker-compose.yml b/docker-compose.yml index b604ef0c..9c510f2f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -23,7 +23,7 @@ services: volumes: - redis_data:/data api: - image: 'ghcr.io/parcelvoy/api:latest' + image: "ghcr.io/parcelvoy/api:${IMAGE_VERSION:-latest}" restart: always healthcheck: test: wget --no-verbose --tries=1 --spider http://localhost:3001/api/health || exit 1 @@ -35,6 +35,7 @@ services: - 3001:3001 links: - mysql:mysql + - redis:redis depends_on: mysql: condition: service_healthy @@ -81,10 +82,11 @@ services: volumes: - uploads:/usr/src/app/public/uploads worker: - image: 'ghcr.io/parcelvoy/api:latest' + image: "ghcr.io/parcelvoy/api:${IMAGE_VERSION:-latest}" restart: always links: - mysql:mysql + - redis:redis depends_on: mysql: condition: service_healthy @@ -128,7 +130,7 @@ services: ERROR_BUGSNAG_API_KEY: ${ERROR_BUGSNAG_API_KEY} ERROR_SENTRY_DSN: ${ERROR_SENTRY_DSN} ui: - image: 'ghcr.io/parcelvoy/ui:latest' + image: "ghcr.io/parcelvoy/ui:${PARCELVOY_VERSION:-latest}" depends_on: api: condition: service_healthy diff --git a/docs/docs/deploy/aws-ec2.md b/docs/docs/deploy/aws-ec2.md index 1806dd89..f69292a3 100644 --- a/docs/docs/deploy/aws-ec2.md +++ b/docs/docs/deploy/aws-ec2.md @@ -3,7 +3,7 @@ title: AWS EC2 --- # Deploy Parcelvoy on AWS (Amazon EC2) -This page guides you through deploying Parcelvoy Open-Source on an Amazon EC2 instance by setting up the deployment environment, installing and starting Airbyte, and connecting it to the Amazon EC2 instance. +This page guides you through deploying Parcelvoy Open-Source on an Amazon EC2 instance by setting up the deployment environment, installing and starting Parcelvoy, and connecting it to the Amazon EC2 instance. ## Requirements​ - A t3.medium instance or larger. While you can run it on smaller instances, performance may not be optimal. @@ -28,7 +28,7 @@ docker compose version 4. Download Parcelvoy configuration: ``` mkdir parcelvoy && cd parcelvoy -wget https://raw.githubusercontent.com/parcelvoy/parcelvoy/master/{.env.example,docker-compose.yaml} +wget https://raw.githubusercontent.com/parcelvoy/platform/master/{.env.example,docker-compose.yml} ``` 5. Setup environment variables @@ -47,4 +47,6 @@ AUTH_BASIC_PASSWORD=password This file also lets you use a separate database, change what queue is being used or setup SSO. By default the port is configured to use `3000` for the UI and API. You can modify this by setting `UI_PORT`. + 6. Setup security groups +Based on what port you are using for the UI portion, you will want to make sure you have configured that port to be open as well in your security groups. diff --git a/docs/docs/overview/quick-start.md b/docs/docs/overview/quick-start.md index 41b0c612..1e0b7ec5 100644 --- a/docs/docs/overview/quick-start.md +++ b/docs/docs/overview/quick-start.md @@ -14,7 +14,7 @@ Copy our latest `docker-compose.yml` and `.env.example` file onto your machine: ``` mkdir parcelvoy && cd parcelvoy -wget https://raw.githubusercontent.com/parcelvoy/parcelvoy/master/{.env.example,docker-compose.yml} +wget https://raw.githubusercontent.com/parcelvoy/platform/master/{.env.example,docker-compose.yml} mv .env.example .env ```