From b34905159084099a70cca6c506ccc561e9c13812 Mon Sep 17 00:00:00 2001 From: Raphael Titsworth-Morin Date: Thu, 19 Sep 2024 20:21:27 +0000 Subject: [PATCH] update config info --- samples/rails/README.md | 8 ++++++++ starter-sample/README.md | 20 ++++++++++++++------ 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/samples/rails/README.md b/samples/rails/README.md index ee63e31a..b44ef8cd 100644 --- a/samples/rails/README.md +++ b/samples/rails/README.md @@ -17,6 +17,14 @@ This template is a member list project developed using Ruby on Rails, offering a 3. Open up a shell in the VS Code terminal and run `docker compose -f compose.dev.yaml up`. +## Configuration + +For this sample, you will need to provide the following [configuration](https://docs.defang.io/docs/concepts/configuration). Note that if you are using the 1-click deploy option, you can set these values as secrets in your GitHub repository and the action will automatically deploy them for you. + +### `POSTGRES_PASSWORD` +This password will be used to initialize the PostgreSQL database and to connect to it. + + ## Deployment > [!NOTE] diff --git a/starter-sample/README.md b/starter-sample/README.md index 24df7e5c..e62054dd 100644 --- a/starter-sample/README.md +++ b/starter-sample/README.md @@ -6,7 +6,7 @@ This is a sample that shows the rough structure of an actual Defang sample. This ## Prerequisites -1. Download [Defang CLI](https://github.com/DefangLabs/defang) +1. [!NOTE] Download [Defang CLI](https://github.com/DefangLabs/defang) 2. (Optional) If you are using [Defang BYOC](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html) authenticated with your AWS account 3. (Optional for local development) [Docker CLI](https://docs.docker.com/engine/install/) @@ -27,13 +27,21 @@ For this sample, you will need to provide the following [configuration](https:// ### `API_KEY` #REMOVE_ME_AFTER_EDITING An explanation of what the env var (`API_KEY`) is, etc. +## Deployment -## Deploying +> [!NOTE] +> Download [Defang CLI](https://github.com/DefangLabs/defang) -1. Open the terminal and type `defang login` -2. Use the [`defang config`](https://docs.defang.io/docs/concepts/compose#configuration) command to setup environment variables. #REMOVE_ME_AFTER_EDITING -3. Type `defang compose up` in the CLI. -4. Your app will be running within a few minutes. +### Defang Playground + +Deploy your application to the defang playground by opening up your terminal and typing `defang up`. + +### BYOC (AWS) + +If you want to deploy to your own cloud account, you can use Defang BYOC: + +1. [Authenticate your AWS account](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html), and that you have properly set your environment variables like `AWS_PROFILE`, `AWS_REGION`, `AWS_ACCESS_KEY_ID`, and `AWS_SECRET_ACCESS_KEY`. +2. Run `defang up` in a terminal that has access to your AWS environment variables. ---