From 242db9c4b2ec0a22c51fda5af55541c2748d6559 Mon Sep 17 00:00:00 2001 From: Aaron Job Date: Fri, 15 Sep 2023 22:33:03 +0000 Subject: [PATCH 1/2] fixed docker health check --- README.md | 3 ++- docker-compose.yml | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 942ba1f..eb31f18 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,7 @@ You specify what kind of an app you want to build. Then, GPT Pilot asks clarifyi * [🔌 Requirements](#-requirements) * [🚦How to start using gpt-pilot?](#how-to-start-using-gpt-pilot) + * [🐳 How to start gpt-pilot in docker?](#how-to-start-using-gpt-pilot-in-docker) * [🧑‍💻️ Other arguments](#%EF%B8%8F-other-arguments) * [🔎 Examples](#-examples) * [Real-time chat app](#-real-time-chat-app) @@ -76,7 +77,7 @@ All generated code will be stored in the folder `workspace` inside the folder na **IMPORTANT: To run GPT Pilot, you need to have PostgreSQL set up on your machine**
-# 🐳 How to start gpt-pilot in docker? +## 🐳 How to start gpt-pilot in docker? 1. `git clone https://github.com/Pythagora-io/gpt-pilot.git` (clone the repo) 2. Update the `docker-compose.yml` environment variables 3. run `docker compose build`. this will build a gpt-pilot container for you. diff --git a/docker-compose.yml b/docker-compose.yml index 6347f7f..df7e4ed 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -20,7 +20,8 @@ services: context: . dockerfile: Dockerfile ports: - - "7681:7681" + - "7681:7681" + - "3000:3000" depends_on: postgres: condition: service_healthy @@ -34,7 +35,7 @@ services: ports: - "5432:5432" healthcheck: - test: ["CMD-SHELL", "pg_isready -U user"] + test: ["CMD-SHELL", "pg_isready -U pilot"] interval: 30s timeout: 10s retries: 3 From 322a003bd2ac0f2af21deb9f4c73bce4bcab419a Mon Sep 17 00:00:00 2001 From: Aaron Job Date: Fri, 15 Sep 2023 22:36:47 +0000 Subject: [PATCH 2/2] fixed doker link --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index eb31f18..7ca495c 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ You specify what kind of an app you want to build. Then, GPT Pilot asks clarifyi * [🔌 Requirements](#-requirements) * [🚦How to start using gpt-pilot?](#how-to-start-using-gpt-pilot) - * [🐳 How to start gpt-pilot in docker?](#how-to-start-using-gpt-pilot-in-docker) + * [🐳 How to start gpt-pilot in docker?](#-how-to-start-gpt-pilot-in-docker) * [🧑‍💻️ Other arguments](#%EF%B8%8F-other-arguments) * [🔎 Examples](#-examples) * [Real-time chat app](#-real-time-chat-app) @@ -86,7 +86,7 @@ All generated code will be stored in the folder `workspace` inside the folder na 6. `python db_init.py` (initialize the database) 7. `python main.py` (start GPT Pilot) -This will start two containers, one being a new image built by the `Dockerfile` and a postgres database. The new image also has [ttyd](https://github.com/tsl0922/ttyd) installed so you can easily interact with gpt-pilot. +This will start two containers, one being a new image built by the `Dockerfile` and a postgres database. The new image also has [ttyd](https://github.com/tsl0922/ttyd) installed so you can easily interact with gpt-pilot. Node is also installed on the image and port 3000 is exposed. # 🧑‍💻️ Other arguments - continue working on an existing app