Skip to content

Commit bdf177a

Browse files
more improvements (#172)
1 parent 32fa5a5 commit bdf177a

File tree

9 files changed

+134
-22
lines changed

9 files changed

+134
-22
lines changed

hello-world/README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@ Run this command from your application's root folder:
2424
```bash
2525
encore run
2626
```
27-
28-
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to view Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
29-
3027
## Using the API
3128

3229
To see that your app is running, you can ping the API.
@@ -35,7 +32,11 @@ To see that your app is running, you can ping the API.
3532
curl http://localhost:4000/hello/World
3633
```
3734

38-
When you ping the API, you will see traces and logs appearing in the local development dashboard: <http://localhost:9400/>
35+
## Local Development Dashboard
36+
37+
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
38+
39+
Here you can see traces for all requests that you made while using the frontend, see your architecture diagram, and view API documentation in the Service Catalog.
3940

4041
## Deployment
4142

slack-bot/README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,13 @@ encore run
7979

8080
**Note:** This app doesn't do much when running locally, you need to deploy it (see below) for Slack to be able to communicate with the program and for the bot to work.
8181

82+
83+
## Local Development Dashboard
84+
85+
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
86+
87+
Here you can see traces for all requests that you made while using the frontend, see your architecture diagram, and view API documentation in the Service Catalog.
88+
8289
## Deployment
8390

8491
### Self-hosting

sql-database/README.md

Lines changed: 33 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -95,33 +95,59 @@ To run the application locally, make sure you have [Docker](https://docker.com)
9595
encore run
9696
```
9797

98-
## Using the API in the example
98+
## Using the API
9999

100100
To see that your app is running, you can ping the API.
101101

102102
```bash
103103
curl http://localhost:4000/hello/There
104104
```
105105

106-
## Open the developer dashboard
106+
## Local Development Dashboard
107107

108-
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to view Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
108+
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
109+
110+
Here you can see traces for all requests that you made while using the frontend, see your architecture diagram, and view API documentation in the Service Catalog.
111+
112+
## Connecting to databases
113+
114+
You can connect to your databases via psql shell:
115+
116+
```bash
117+
encore db shell <database-name> --env=local --superuser
118+
```
119+
120+
Learn more in the [CLI docs](https://encore.dev/docs/develop/cli-reference#database-management).
109121

110122
## Deployment
111123

112-
Deploy your application to a staging environment in Encore's free development cloud:
124+
### Self-hosting
125+
126+
See the [self-hosting instructions](https://encore.dev/docs/self-host/docker-build) for how to use `encore build docker` to create a Docker image and configure it.
127+
128+
### Encore Cloud Platform
129+
130+
Deploy your application to a free staging environment in Encore's development cloud using `git push encore`:
113131

114132
```bash
115133
git add -A .
116134
git commit -m 'Commit message'
117135
git push encore
118136
```
119137

120-
Then head over to the [Cloud Dashboard](https://app.encore.dev) to monitor your deployment and find your production URL.
138+
You can also open your app in the [Cloud Dashboard](https://app.encore.dev) to integrate with GitHub, or connect your AWS/GCP account, enabling Encore to automatically handle cloud deployments for you.
139+
140+
## Link to GitHub
141+
142+
Follow these steps to link your app to GitHub:
121143

122-
From there you can also connect your own AWS or GCP account to use for deployment.
144+
1. Create a GitHub repo, commit and push the app.
145+
2. Open your app in the [Cloud Dashboard](https://app.encore.dev).
146+
3. Go to **Settings ➔ GitHub** and click on **Link app to GitHub** to link your app to GitHub and select the repo you just created.
147+
4. To configure Encore to automatically trigger deploys when you push to a specific branch name, go to the **Overview** page for your intended environment. Click on **Settings** and then in the section **Branch Push** configure the **Branch name** and hit **Save**.
148+
5. Commit and push a change to GitHub to trigger a deploy.
123149

124-
Now off you go into the clouds!
150+
[Learn more in the docs](https://encore.dev/docs/how-to/github)
125151

126152
## Testing
127153

ts/hello-world/README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@ Run this command from your application's root folder:
2424
```bash
2525
encore run
2626
```
27-
28-
While `encore run` is running, open <http://localhost:9400/> to view Encore's [local development dashboard](https://encore.dev/docs/observability/dev-dash).
29-
3027
## Using the API
3128

3229
To see that your app is running, you can ping the API.
@@ -35,7 +32,11 @@ To see that your app is running, you can ping the API.
3532
curl http://localhost:4000/hello/World
3633
```
3734

38-
When you ping the API, you will see traces and logs appearing in the local development dashboard: <http://localhost:9400/>
35+
## Local Development Dashboard
36+
37+
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
38+
39+
Here you can see traces for all requests that you made while using the frontend, see your architecture diagram, and view API documentation in the Service Catalog.
3940

4041
## Deployment
4142

ts/slack-bot/README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
This is an Encore starter application for a Slack bot. It brings the greatness of the cowsay utility to Slack!
44

5+
## Build from scratch with a tutorial
6+
7+
If you prefer to built it yourself, check out the [written tutorial](https://encore.dev/docs/tutorials/slack-bot) to learn how to build this application from scratch.
8+
59
## Prerequisites
610

711
**Install Encore:**
@@ -75,6 +79,12 @@ encore run
7579

7680
**Note:** This app doesn't do much when running locally, you need to deploy it (see below) for Slack to be able to communicate with the program and for the bot to work.
7781

82+
## Local Development Dashboard
83+
84+
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
85+
86+
Here you can see traces for all requests that you made while using the frontend, see your architecture diagram, and view API documentation in the Service Catalog.
87+
7888
## Deployment
7989

8090
### Self-hosting

ts/uptime/README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,16 @@ While `encore run` is running, open [http://localhost:9400/](http://localhost:94
8282

8383
Here you can see traces for all requests that you made while using the frontend, see your architecture diagram, and view API documentation in the Service Catalog.
8484

85+
## Connecting to databases
86+
87+
You can connect to your databases via psql shell:
88+
89+
```bash
90+
encore db shell <database-name> --env=local --superuser
91+
```
92+
93+
Learn more in the [CLI docs](https://encore.dev/docs/develop/cli-reference#database-management).
94+
8595
## Deployment
8696

8797
### Self-hosting

ts/url-shortener/README.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,26 @@ Before running your application, make sure you have Docker installed and running
3434
encore run
3535
```
3636

37+
## Using the API
38+
39+
### url.shorten — Shortens a URL and adds it to the database
40+
41+
```bash
42+
curl 'http://127.0.0.1:4000/url' -d '{"url":"https://google.com"}'
43+
```
44+
45+
### url.get — Gets a URL from the database using a short ID
46+
47+
```bash
48+
curl 'http://127.0.0.1:4000/url/:id'
49+
```
50+
51+
### url.list — Lists all shortened URLs
52+
53+
```bash
54+
curl 'http://127.0.0.1:4000/url'
55+
```
56+
3757
## Open the developer dashboard
3858

3959
While `encore run` is running, open <http://localhost:9400/> to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
@@ -50,6 +70,16 @@ curl 'http://localhost:4000/url' -d '{"url":"https://news.ycombinator.com"}'
5070

5171
When you ping the API, you will see traces and logs appearing in the local development dashboard: <http://localhost:9400/>
5272

73+
## Connecting to databases
74+
75+
You can connect to your databases via psql shell:
76+
77+
```bash
78+
encore db shell <database-name> --env=local --superuser
79+
```
80+
81+
Learn more in the [CLI docs](https://encore.dev/docs/develop/cli-reference#database-management).
82+
5383
## Deployment
5484

5585
### Self-hosting

uptime/README.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,6 @@ encore secret set --type local,dev,pr,prod SlackWebhookURL
4949

5050
**Note:** Cron Jobs do not execute when running locally.
5151

52-
## Local Development Dashboard
53-
54-
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
55-
56-
Here you can see traces for all requests, see the application architecture diagram, and see API documentation in the Service Catalog.
57-
5852
## View the frontend
5953

6054
While `encore run` is running, head over to [http://localhost:4000/frontend/](http://localhost:4000/frontend/) to view the frontend for your uptime monitor.
@@ -81,6 +75,22 @@ Get the current status of all tracked sites:
8175
curl 'http://localhost:4000/status'
8276
```
8377

78+
## Local Development Dashboard
79+
80+
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
81+
82+
Here you can see traces for all requests you've made, see the application architecture diagram, and see API documentation in the Service Catalog.
83+
84+
## Connecting to databases
85+
86+
You can connect to your databases via psql shell:
87+
88+
```bash
89+
encore db shell <database-name> --env=local --superuser
90+
```
91+
92+
Learn more in the [CLI docs](https://encore.dev/docs/develop/cli-reference#database-management).
93+
8494
## Deployment
8595

8696
### Self-hosting

url-shortener/README.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,18 +35,35 @@ encore run
3535

3636
## Using the API
3737

38-
To see that your app is running, you can ping the API to shorten a url.
38+
39+
### url.shorten — Shortens a URL and adds it to the database
3940

4041
```bash
4142
curl 'http://localhost:4000/url' -d '{"URL":"https://news.ycombinator.com"}'
4243
```
4344

45+
### url.get — Gets a URL from the database using a short ID
46+
47+
```bash
48+
curl 'http://127.0.0.1:4000/url/:id'
49+
```
50+
4451
## Open the developer dashboard
4552

4653
While `encore run` is running, open [http://localhost:9400/](http://localhost:9400/) to access Encore's [local developer dashboard](https://encore.dev/docs/observability/dev-dash).
4754

4855
Here you can see traces for all your requests, view your architecture diagram, and see API docs in the Service Catalog.
4956

57+
## Connecting to databases
58+
59+
You can connect to your databases via psql shell:
60+
61+
```bash
62+
encore db shell <database-name> --env=local --superuser
63+
```
64+
65+
Learn more in the [CLI docs](https://encore.dev/docs/develop/cli-reference#database-management).
66+
5067
## Deployment
5168

5269
### Self-hosting

0 commit comments

Comments
 (0)