You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -82,17 +82,17 @@ Join the community [Slack channel](https://www.aserto.com/slack) for questions a
82
82
1. Clone the repo
83
83
2. Build and run the executable
84
84
85
-
```shell
86
-
make build && ./dist/build_linux_amd64/topaz
87
-
```
85
+
```console
86
+
$make build && ./dist/build_linux_amd64/topaz
87
+
```
88
88
89
89
### Running with Docker
90
90
91
91
You can run as a Docker container:
92
92
93
-
```shell
94
-
docker run -it --rm ghcr.io/aserto-dev/topaz:latest --help
95
-
```
93
+
```console
94
+
$docker run -it --rm ghcr.io/aserto-dev/topaz:latest --help
95
+
```
96
96
97
97
## Quickstart
98
98
@@ -102,8 +102,8 @@ These instructions help you get Topaz up and running as the authorizer for a sam
102
102
103
103
The Topaz authorizer is packaged as a Docker container. You can get the latest image using the following command:
104
104
105
-
```shell
106
-
topaz install
105
+
```console
106
+
$ topaz install
107
107
```
108
108
109
109
**NOTE:** If you get the following errors/warnings from Topaz commands:
@@ -121,16 +121,16 @@ Topaz has a set of pre-built templates that contain three types of artifacts:
121
121
122
122
You can use the CLI to install the todo template:
123
123
124
-
```shell
125
-
topaz templates install todo
124
+
```console
125
+
$ topaz templates install todo
126
126
```
127
127
128
128
#### Artifacts
129
129
130
130
This command will install the following artifacts in `$HOME/.config/topaz/`:
131
131
132
-
```shell
133
-
tree $HOME/.config/topaz
132
+
```console
133
+
$ tree $HOME/.config/topaz
134
134
/Users/ogazitt/.config/topaz
135
135
├── cfg
136
136
│ └── todo.yaml
@@ -148,8 +148,8 @@ tree $HOME/.config/topaz
148
148
*`todo/data/` contains the objects and relations for the Todo template - in this case, a set of 5 users and 4 groups that are based on the "Rick & Morty" cartoon.
149
149
*`todo/model/manifest.yaml` contains the manifest file which describes the domain model.
150
150
151
-
```shell
152
-
tree ~/.local/share/topaz
151
+
```console
152
+
$ tree ~/.local/share/topaz
153
153
/Users/ogazitt/.local/share/topaz
154
154
├── certs
155
155
│ ├── gateway-ca.crt
@@ -194,16 +194,16 @@ To verify that Topaz is running with the right policy image, you can issue a `cu
194
194
195
195
This API call retrieves the set of policies that Topaz has loaded:
196
196
197
-
```shell
198
-
curl -k https://localhost:8383/api/v2/policies
197
+
```console
198
+
$ curl -k https://localhost:8383/api/v2/policies
199
199
```
200
200
201
201
### Issue an authorization request
202
202
203
203
Issue an authorization request using the `is` REST API to verify that the user Rick is allowed to GET the list of todos:
204
204
205
-
```shell
206
-
curl -k -X POST 'https://localhost:8383/api/v2/authz/is' \
205
+
```console
206
+
$ curl -k -X POST 'https://localhost:8383/api/v2/authz/is' \
207
207
-H 'Content-Type: application/json' \
208
208
-d '{
209
209
"identity_context": {
@@ -225,8 +225,9 @@ To start an interactive session with the Topaz endpoints over gRPC, see the [gRP
225
225
226
226
## Command line options
227
227
228
-
```shell
229
-
topaz --help
228
+
```console
229
+
$ topaz --help
230
+
230
231
Usage: topaz <command> [flags]
231
232
232
233
Topaz CLI
@@ -261,14 +262,14 @@ Run "topaz <command> --help" for more information on a command.
261
262
262
263
To interact with the authorizer endpoint, install [grpcui](https://github.com/fullstorydev/grpcui) or [grpcurl](https://github.com/fullstorydev/grpcurl) and point them to `localhost:8282`:
263
264
264
-
```shell
265
-
grpcui --insecure localhost:8282
265
+
```console
266
+
$ grpcui --insecure localhost:8282
266
267
```
267
268
268
269
To interact with the directory endpoint, use `localhost:9292`:
269
270
270
-
```shell
271
-
grpcui --insecure localhost:9292
271
+
```console
272
+
$ grpcui --insecure localhost:9292
272
273
```
273
274
274
275
For more information on APIs, see the [docs](https://www.topaz.sh/docs/intro).
0 commit comments