Skip to content
This repository was archived by the owner on May 20, 2025. It is now read-only.

Commit 04eaddd

Browse files
review suggestions
1 parent d5bd34e commit 04eaddd

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

docs/guides/go/realtime-messaging.mdx

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title_seo: Building your first WebSocket Application with Go and Nitric
3-
description: Use the Nitric framework to easily build and deploy Go WebSocket applications for AWS, Azure or Google Cloud.
3+
description: Use the Nitric framework to easily build and deploy Go WebSocket applications for AWS.
44
tags:
55
- Realtime & Websockets
66
- Key Value Store
@@ -140,7 +140,7 @@ ws.On(websockets.EventType_Message, func(ctx *websockets.Ctx) {
140140
if err != nil {
141141
return
142142
}
143-
143+
144144
senderId := ctx.Request.ConnectionID()
145145

146146
for {
@@ -239,7 +239,14 @@ Do a quick `go mod tidy` to make sure all new dependencies are resolved.
239239

240240
## Ok, let's run this thing!
241241

242-
Now that you have your WebSocket application defined with handlers for each event, it's time to test it locally.
242+
Now that you have your WebSocket application defined with handlers for each event, it's time to test it locally. Update your `nitric.yaml` to point to the service at `websockets/main.go`:
243+
244+
```yaml
245+
services:
246+
- match: websockets/*
247+
runtime: go
248+
start: go run ./$SERVICE_PATH
249+
```
243250
244251
```bash
245252
nitric start
@@ -265,7 +272,10 @@ Continue by checking your stack file `nitric.dev.yaml` and adding in your prefer
265272

266273
### AWS
267274

268-
Note: You are responsible for staying within the limits of the free tier or any costs associated with deployment.
275+
<Note>
276+
You are responsible for staying within the limits of the free tier or any
277+
costs associated with deployment.
278+
</Note>
269279

270280
We called our stack `dev`. Let's try deploying it with the `up` command:
271281

0 commit comments

Comments
 (0)