Skip to content

Commit 82bf346

Browse files
committed
Improve readme
1 parent 67ed9d0 commit 82bf346

File tree

1 file changed

+17
-16
lines changed

1 file changed

+17
-16
lines changed

backend/api/README.md

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,21 @@ gcloud compute backend-services update api-backend \
6565
--timeout=600s
6666
```
6767

68-
#### API Deploy CD
68+
Set up the saved search notifications job:
69+
70+
```bash
71+
gcloud scheduler jobs create http daily-saved-search-notifications \
72+
--schedule="0 16 * * *" \
73+
--uri="https://api.compassmeet.com/internal/send-search-notifications" \
74+
--http-method=POST \
75+
--headers="x-api-key=<API_KEY>" \
76+
--time-zone="UTC" \
77+
--location=us-west1
78+
```
79+
80+
View it [here](https://console.cloud.google.com/cloudscheduler).
81+
82+
##### API Deploy CD
6983

7084
```shell
7185
gcloud iam service-accounts create ci-deployer \
@@ -89,20 +103,6 @@ gcloud iam service-accounts add-iam-policy-binding \
89103
gcloud iam service-accounts keys create keyfile.json [email protected]
90104
```
91105

92-
Set up the saved search notifications job:
93-
94-
```bash
95-
gcloud scheduler jobs create http daily-saved-search-notifications \
96-
--schedule="0 16 * * *" \
97-
--uri="https://api.compassmeet.com/internal/send-search-notifications" \
98-
--http-method=POST \
99-
--headers="x-api-key=<API_KEY>" \
100-
--time-zone="UTC" \
101-
--location=us-west1
102-
```
103-
104-
View it [here](https://console.cloud.google.com/cloudscheduler).
105-
106106
##### DNS
107107

108108
* After deployment, Terraform assigns a static external IP to this resource.
@@ -164,8 +164,9 @@ In root directory, run the local api with hot reload, along with all the other b
164164

165165
### Deploy
166166

167-
Run in this directory to deploy your code to the server.
167+
To deploy the backend code, simply increment the version number in [package.json](package.json) and push to the `main` branch.
168168

169+
Or if you have access to the project on google cloud, run in this directory:
169170
```bash
170171
./deploy-api.sh prod
171172
```

0 commit comments

Comments
 (0)