Skip to content

Commit

Permalink
autogen(docs): generate cli docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ory-bot committed Oct 17, 2024
1 parent 2d2417a commit 8c7f64c
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 22 deletions.
20 changes: 10 additions & 10 deletions docs/cli/ory-proxy.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ Per default, CORS is enabled for all origins.

### Connecting in automated environments

To connect the Ory Tunnel in automated environments, create a Project API Key for your project and set it as an environment variable:
To connect the Ory Tunnel in automated environments, create a Project API Key for your project, set it as an environment variable, and use the `--quiet` flag:

$ %[2]s=<project-api-key> ory proxy tunnel ...
$ %[2]s=<project-api-key> ory proxy -q ...

This will prevent the browser window from opening.

Expand All @@ -70,8 +70,8 @@ This will prevent the browser window from opening.
If you are using the Ory Proxy behind a gateway during development, you must set the `publish-url` argument:

$ ory proxy --project <project-id-or-slug> \
http://localhost:3000 \
https://gateway.local:5000
http://localhost:3000 \
https://gateway.local:5000

Note: You cannot set a path in the `publish-url`.

Expand All @@ -86,18 +86,18 @@ By default, the proxy listens on port 4000. To change this, use the `--port` fla
If the proxy runs on a subdomain and you want Ory’s cookies (e.g., session cookies) to be accessible across all your domains, use the `--cookie-domain` flag to customize the cookie domain. Additionally, allow your subdomains in the CORS headers:

$ ory proxy --project <project-id-or-slug> \
--cookie-domain gateway.local \
http://127.0.0.1:3000 \
https://ory.gateway.local
--cookie-domain gateway.local \
http://127.0.0.1:3000 \
https://ory.gateway.local

### Redirects

By default, all redirects will point to `publish-url`. You can customize this behavior using the `--default-redirect-url` flag:

$ ory proxy --project <project-id-or-slug> \
--default-redirect-url /welcome \
http://127.0.0.1:3000 \
https://ory.example.org
--default-redirect-url /welcome \
http://127.0.0.1:3000 \
https://ory.example.org

This ensures that all redirects (e.g., after login) go to `/welcome` instead of `/`, unless you’ve specified custom redirects in your Ory configuration or via the flow’s `?return_to=` query parameter.

Expand Down
24 changes: 12 additions & 12 deletions docs/cli/ory-tunnel.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@ Before using the Ory Tunnel, ensure that you have a running Ory Network project.
Once your project is ready, pass the project's slug to the tunnel command:

$ ory tunnel --project <project-id-or-slug> ...
$ ORY_PROJECT=<project-id-or-slug> ory tunnel tunnel ...
$ ORY_PROJECT=<project-id-or-slug> ory tunnel ...

### Connecting in automated environments

To connect the Ory Tunnel in automated environments, create a Project API Key for your project and set it as an environment variable:
To connect the Ory Tunnel in automated environments, create a Project API Key for your project, set it as an environment variable, and use the `--quiet` flag:

$ ORY_PROJECT_API_KEY=<project-api-key> ory tunnel tunnel ...
$ ORY_PROJECT_API_KEY=<project-api-key> ory tunnel -q ...

This will prevent the browser window from opening.

Expand Down Expand Up @@ -71,9 +71,9 @@ If you need to run the tunnel behind a gateway during development, you can speci
Example:

$ ory tunnel --project <project-id-or-slug> \
https://www.example.org \
https://auth.example.org \
--cookie-domain example.org
https://www.example.org \
https://auth.example.org \
--cookie-domain example.org

Note: You cannot set a path in the `tunnel-url`.

Expand All @@ -92,17 +92,17 @@ If your application runs on a non-standard HTTP or HTTPS port, include the port
For cookie support, set the `--cookie-domain` flag to your top-level domain:

$ ory tunnel --project <project-id-or-slug> \
--cookie-domain example.org \
https://www.example.org \
https://auth.example.org
--cookie-domain example.org \
https://www.example.org \
https://auth.example.org

### Redirects

To specify a custom redirect URL, use the `--default-redirect-url` flag:

$ ory tunnel tunnel --project <project-id-or-slug> \
--default-redirect-url /welcome \
https://www.example.org
$ ory tunnel --project <project-id-or-slug> \
--default-redirect-url /welcome \
https://www.example.org

```
ory tunnel <application-url> [<tunnel-url>] [flags]
Expand Down

0 comments on commit 8c7f64c

Please sign in to comment.