Skip to content

Commit 5611d7c

Browse files
authored
feat: create new cloud page (#436)
1 parent 850506c commit 5611d7c

File tree

7 files changed

+137
-162
lines changed

7 files changed

+137
-162
lines changed

pages/authzed/guides/_meta.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
export default {
2+
"picking-a-product": "Picking a Product",
3+
cloud: "Getting Started with Authzed Cloud",
4+
};

pages/authzed/guides/cloud.mdx

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
import { Callout } from "nextra/components";
2+
import YouTube from "react-youtube";
3+
4+
# Getting Started with AuthZed Cloud
5+
6+
This page provides a guide on how to get up and running with a permission system in AuthZed Cloud.
7+
8+
If you prefer a guide in video format, watch this:
9+
10+
<YouTube videoId="O325tG4s66g" className="youtubeContainer" />
11+
12+
## Create a Permissions System on AuthZed Cloud
13+
14+
Sign in to [AuthZed Cloud](https://app.authzed.cloud) and click on the **+Create** button to create a Permissions System (PS) and fill in the necessary details:
15+
16+
- The type can be either "Production" or "Development".
17+
- Give it a name.
18+
- Choose the underlying datastore.
19+
- The update channel can be either be `rapid` or `regular` which determines the behavior of automatic updates when new SpiceDB releases are made available:
20+
- `rapid` gets the latest release immediately.
21+
- `regular` is one release behind.
22+
- Add SpiceDB deployments:
23+
- Give them a name.
24+
- Choose the region where the deployment will live.
25+
- Choose the number of vCPUs for your deployment. The recommendation is to start with 2 vCPUs and then monitor the Metrics and change it based on your workload.
26+
- Choose the number of replicas to deploy SpiceDB with primarily read workloads. The recommendation is 3 but will depend on your latency requirements.
27+
28+
## Configuring Access
29+
30+
Before using the Permissions System, let's configure access to it.
31+
This functionality enables organizations to apply the principle of least-privilege to services accessing SpiceDB.
32+
For example, read-only tokens can be created for services that should never need to write to SpiceDB.
33+
Read more about it [here](https://authzed.com/docs/authzed/concepts/restricted-api-access)
34+
35+
Let’s start by creating a **Service Account** which is something that represents your unique workload.
36+
We recommend creating a Service Account for each application that will access the SpiceDB API.
37+
Add a name such as `blog-app` and a description before hitting Save.
38+
39+
Now let’s create a **token**.
40+
Tokens are long-lived credentials for Service Accounts.
41+
SpiceDB clients must provide a Token in the Authorization header of an API request to perform actions granted to the Service Account.
42+
Click on the `blog-app` service account you just created and then the Tokens item in the menu.
43+
Create a token by providing a name and description.
44+
45+
Let’s now provide a **Role** and attach a **Policy** to that Role.
46+
A Role defines rules for accessing the SpiceDB API.
47+
Roles are bound to Service Accounts.
48+
Click the Roles -> Create Role and provide a name and a description.
49+
Add the following permissions for this demo:
50+
51+
```
52+
ReadSchema
53+
WriteSchema
54+
DeleteRelationships
55+
ReadRelationships
56+
WriteRelationships
57+
CheckPermission
58+
```
59+
60+
Finally, let’s create a Policy.
61+
Policies are what bind Roles to a Service Account.
62+
Click on Policies -> Create policy.
63+
Provide a name and a description and pick the Service Account and Role created in the steps above to bind the two.
64+
65+
You’re now ready to use your Permissions System!

pages/spicedb/concepts/commands.mdx

Lines changed: 11 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,12 @@ A database that stores and computes permissions
2727

2828
### Children commands
2929

30-
- [spicedb datastore](#reference-spicedb-datastore) - datastore operations
31-
- [spicedb lsp](#reference-spicedb-lsp) - serve language server protocol
32-
- [spicedb man](#reference-spicedb-man) - Generate man page
33-
- [spicedb serve](#reference-spicedb-serve) - serve the permissions database
34-
- [spicedb serve-testing](#reference-spicedb-serve-testing) - test server with an in-memory datastore
35-
- [spicedb version](#reference-spicedb-version) - displays the version of SpiceDB
36-
30+
- [spicedb datastore](#reference-spicedb-datastore) - datastore operations
31+
- [spicedb lsp](#reference-spicedb-lsp) - serve language server protocol
32+
- [spicedb man](#reference-spicedb-man) - Generate man page
33+
- [spicedb serve](#reference-spicedb-serve) - serve the permissions database
34+
- [spicedb serve-testing](#reference-spicedb-serve-testing) - test server with an in-memory datastore
35+
- [spicedb version](#reference-spicedb-version) - displays the version of SpiceDB
3736

3837
## Reference: `spicedb datastore`
3938

@@ -49,11 +48,10 @@ Operations against the configured datastore
4948

5049
### Children commands
5150

52-
- [spicedb datastore gc](#reference-spicedb-datastore-gc) - executes garbage collection
53-
- [spicedb datastore head](#reference-spicedb-datastore-head) - compute the head (latest) database migration revision available
54-
- [spicedb datastore migrate](#reference-spicedb-datastore-migrate) - execute datastore schema migrations
55-
- [spicedb datastore repair](#reference-spicedb-datastore-repair) - executes datastore repair
56-
51+
- [spicedb datastore gc](#reference-spicedb-datastore-gc) - executes garbage collection
52+
- [spicedb datastore head](#reference-spicedb-datastore-head) - compute the head (latest) database migration revision available
53+
- [spicedb datastore migrate](#reference-spicedb-datastore-migrate) - execute datastore schema migrations
54+
- [spicedb datastore repair](#reference-spicedb-datastore-repair) - executes datastore repair
5755

5856
## Reference: `spicedb datastore gc`
5957

@@ -148,8 +146,6 @@ spicedb datastore gc [flags]
148146
--skip-release-check if true, skips checking for new SpiceDB releases
149147
```
150148

151-
152-
153149
## Reference: `spicedb datastore head`
154150

155151
compute the head (latest) database migration revision available
@@ -181,8 +177,6 @@ spicedb datastore head [flags]
181177
--skip-release-check if true, skips checking for new SpiceDB releases
182178
```
183179

184-
185-
186180
## Reference: `spicedb datastore migrate`
187181

188182
Executes datastore schema migrations for the datastore.
@@ -222,8 +216,6 @@ spicedb datastore migrate [revision] [flags]
222216
--skip-release-check if true, skips checking for new SpiceDB releases
223217
```
224218

225-
226-
227219
## Reference: `spicedb datastore repair`
228220

229221
Executes a repair operation for the datastore
@@ -317,8 +309,6 @@ spicedb datastore repair [flags]
317309
--skip-release-check if true, skips checking for new SpiceDB releases
318310
```
319311

320-
321-
322312
## Reference: `spicedb lsp`
323313

324314
serve language server protocol
@@ -342,20 +332,17 @@ spicedb lsp [flags]
342332
--skip-release-check if true, skips checking for new SpiceDB releases
343333
```
344334

345-
346-
347335
## Reference: `spicedb man`
348336

349337
Generate a man page for SpiceDB.
350-
The output can be redirected to a file and installed to the system:
338+
The output can be redirected to a file and installed to the system:
351339

352340
```
353341
spicedb man > spicedb.1
354342
sudo mv spicedb.1 /usr/share/man/man1/
355343
sudo mandb # Update man page database
356344
```
357345

358-
359346
```
360347
spicedb man
361348
```
@@ -368,8 +355,6 @@ spicedb man
368355
--skip-release-check if true, skips checking for new SpiceDB releases
369356
```
370357

371-
372-
373358
## Reference: `spicedb serve`
374359

375360
start a SpiceDB server
@@ -557,8 +542,6 @@ spicedb serve [flags]
557542
--skip-release-check if true, skips checking for new SpiceDB releases
558543
```
559544

560-
561-
562545
## Reference: `spicedb serve-testing`
563546

564547
An in-memory spicedb server which serves completely isolated datastores per client-supplied auth token used.
@@ -620,8 +603,6 @@ spicedb serve-testing [flags]
620603
--skip-release-check if true, skips checking for new SpiceDB releases
621604
```
622605

623-
624-
625606
## Reference: `spicedb version`
626607

627608
displays the version of SpiceDB
@@ -643,6 +624,3 @@ spicedb version [flags]
643624
--log-level string verbosity of logging ("trace", "debug", "info", "warn", "error") (default "info")
644625
--skip-release-check if true, skips checking for new SpiceDB releases
645626
```
646-
647-
648-

pages/spicedb/getting-started/_meta.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@ export default {
55
"client-libraries": "Client Libraries",
66
"installing-zed": "Installing the CLI",
77
"coming-from": "Coming From",
8-
"protecting-a-blog": "Example: Protecting a Blog Application",
8+
"protecting-a-blog": "Tutorial: Protecting a Blog Application",
99
faq: "FAQ",
1010
};

0 commit comments

Comments
 (0)