Skip to content

Commit

Permalink
update config info
Browse files Browse the repository at this point in the history
  • Loading branch information
raphaeltm committed Sep 19, 2024
1 parent 994401f commit b349051
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 6 deletions.
8 changes: 8 additions & 0 deletions samples/rails/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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]
Expand Down
20 changes: 14 additions & 6 deletions starter-sample/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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/)

Expand All @@ -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.

---

Expand Down

0 comments on commit b349051

Please sign in to comment.