Skip to content

Commit

Permalink
website/docs: ensure yaml code blocks have language tags
Browse files Browse the repository at this point in the history
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
  • Loading branch information
BeryJu committed Apr 12, 2024
1 parent 7ef14eb commit 23ffd98
Show file tree
Hide file tree
Showing 21 changed files with 42 additions and 40 deletions.
2 changes: 1 addition & 1 deletion website/docs/core/certificates.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ You can also bind mount single files into the folder, as long as they fall under
- Files can be in any arbitrary file structure, and can have any extension.
- If the path contains `archive`, the files will be ignored (to better support certbot setups).

```
```shell
certs/
├── baz
│   └── bar.baz
Expand Down
4 changes: 2 additions & 2 deletions website/docs/installation/kubernetes.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ You can also [view a video walk-through](https://www.youtube.com/watch?v=O1qUbrk

Start by generating passwords for the database and cache. You can use either of the following commands:

```
```shell
pwgen -s 50 1
openssl rand -base64 36
```
Expand Down Expand Up @@ -62,7 +62,7 @@ See all configurable values on [ArtifactHub](https://artifacthub.io/packages/hel
Now, execute the following commands to install authentik:
```
```shell
helm repo add authentik https://charts.goauthentik.io
helm repo update
helm upgrade --install authentik authentik/authentik -f values.yaml
Expand Down
4 changes: 2 additions & 2 deletions website/docs/providers/ldap/generic_setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,14 +74,14 @@ Test connectivity by using ldapsearch.
:::info
ldapsearch can be installed on Linux system with these commands

```
```shell
sudo apt-get install ldap-utils -y # Debian-based systems
sudo yum install openldap-clients -y # CentOS-based systems
```

:::

```
```shell
ldapsearch \
-x \
-H ldap://<LDAP Outpost IP address>:<Port number 389> \ # In production it is recommended to use SSL, which also requires `ldaps://` as the protocol and the SSL port
Expand Down
2 changes: 1 addition & 1 deletion website/docs/releases/2023/v2023.10.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ This release does not introduce any new requirements.

To upgrade, download the new docker-compose file and update the Docker stack with the new version, using these commands:

```
```shell
wget -O docker-compose.yml https://goauthentik.io/version/2023.10/docker-compose.yml
docker-compose up -d
```
Expand Down
2 changes: 1 addition & 1 deletion website/docs/releases/2023/v2023.5.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ This release does not introduce any new requirements.

To upgrade, download the new docker-compose file and update the Docker stack with the new version, using these commands:

```
```shell
wget -O docker-compose.yml https://goauthentik.io/version/2023.5/docker-compose.yml
docker-compose up -d
```
Expand Down
2 changes: 1 addition & 1 deletion website/docs/releases/2023/v2023.6.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ This release does not introduce any new requirements.

To upgrade, download the new docker-compose file and update the Docker stack with the new version, using these commands:

```
```shell
wget -O docker-compose.yml https://goauthentik.io/version/2023.6/docker-compose.yml
docker-compose up -d
```
Expand Down
2 changes: 1 addition & 1 deletion website/docs/releases/2023/v2023.8.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ This release changes the PostgreSQL dependency to require Version 12 or later, w

To upgrade, download the new docker-compose file and update the Docker stack with the new version, using these commands:

```
```shell
wget -O docker-compose.yml https://goauthentik.io/version/2023.8/docker-compose.yml
docker-compose up -d
```
Expand Down
2 changes: 1 addition & 1 deletion website/docs/releases/2024/next.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ This release does not introduce any new requirements.

To upgrade, download the new docker-compose file and update the Docker stack with the new version, using these commands:

```
```shell
wget -O docker-compose.yml https://goauthentik.io/version/xxxx.x/docker-compose.yml
docker compose up -d
```
Expand Down
2 changes: 1 addition & 1 deletion website/docs/releases/2024/v2024.2.md
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ This release does not introduce any new requirements, but contains some breaking

To upgrade, download the new docker-compose file and update the Docker stack with the new version, using these commands:

```
```shell
wget -O docker-compose.yml https://goauthentik.io/version/2024.2/docker-compose.yml
docker compose up -d
```
Expand Down
2 changes: 1 addition & 1 deletion website/docs/releases/_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ This release does not introduce any new requirements.

To upgrade, download the new docker-compose file and update the Docker stack with the new version, using these commands:

```
```shell
wget -O docker-compose.yml https://goauthentik.io/version/xxxx.x/docker-compose.yml
docker compose up -d
```
Expand Down
2 changes: 1 addition & 1 deletion website/docs/releases/old/v0.10.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ By default, the new compose file uses a fixed version to prevent unintended upda

Before updating the file, stop all containers. Then download the file, pull the new containers and start the database.

```
```shell
docker-compose down
docker-compose pull
docker-compose up --no-start
Expand Down
6 changes: 3 additions & 3 deletions website/docs/releases/old/v0.13.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ The only manual change you have to do is replace the `PASSBOOK_` prefix in your

Additionally, the database name and username have to be changed, so add this block to your `.env` file:

```
```shell
PG_USER=passbook
PG_DB=passbook
```
Expand All @@ -50,7 +50,7 @@ Afterwards, you can simply run `docker-compose up -d` and then the normal upgrad

The helm repository changes from passbook to authentik. To update your repository, execute these commands:

```
```shell
helm repo remove passbook
helm repo add authentik https://docker.beryju.org/chartrepo/authentik
```
Expand All @@ -68,7 +68,7 @@ postgresql:
Afterwards you can upgrade as usual from the new repository:
```
```shell
helm upgrade authentik authentik/authentik --devel -f values.yaml
```

Expand Down
8 changes: 4 additions & 4 deletions website/docs/releases/old/v0.9.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ To export data from your old instance, run this command:

- docker-compose

```
```shell
docker-compose exec server ./manage.py dumpdata -o /tmp/authentik_dump.json authentik_core.User authentik_core.Group authentik_crypto.CertificateKeyPair authentik_audit.Event otp_totp.totpdevice otp_static.staticdevice otp_static.statictoken
docker cp authentik_server_1:/tmp/authentik_dump.json authentik_dump.json
```

- kubernetes

```
```shell
kubectl exec -it authentik-web-... -- ./manage.py dumpdata -o /tmp/authentik_dump.json authentik_core.User authentik_core.Group authentik_crypto.CertificateKeyPair authentik_audit.Event otp_totp.totpdevice otp_static.staticdevice otp_static.statictoken
kubectl cp authentik-web-...:/tmp/authentik_dump.json authentik_dump.json
```
Expand All @@ -25,14 +25,14 @@ After that, create a new authentik instance in a different namespace (kubernetes

- docker-compose

```
```shell
docker cp authentik_dump.json new_authentik_server_1:/tmp/authentik_dump.json
docker-compose exec server ./manage.py loaddata /tmp/authentik_dump.json
```

- kubernetes

```
```shell
kubectl cp authentik_dump.json authentik-web-...:/tmp/authentik_dump.json
kubectl exec -it authentik-web-... -- ./manage.py loaddata /tmp/authentik_dump.json
```
Expand Down
6 changes: 3 additions & 3 deletions website/docs/troubleshooting/emails.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,20 @@ Some hosting providers block outgoing SMTP ports, in which case you'll have to h

To test if an email stage, or the global email settings are configured correctly, you can run the following command:

```
```shell
ak test_email <to address> [-S <stage name>]
```

If you omit the `-S` parameter, the email will be sent using the global settings. Otherwise, the settings of the specified stage will be used.

To run this command with docker-compose, use

```
```shell
docker compose exec worker ak test_email [...]
```

To run this command with Kubernetes, use

```
```shell
kubectl exec -it deployment/authentik-worker -c authentik -- ak test_email [...]
```
8 changes: 4 additions & 4 deletions website/docs/troubleshooting/ldap_source.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,24 @@ title: Troubleshooting LDAP Synchronization

To troubleshoot LDAP sources, you can run the command below to run a synchronization in the foreground and see any errors or warnings that might happen directly

```
```shell
docker compose run --rm worker ldap_sync *slug of the source*
```

or, for Kubernetes, run

```
```shell
kubectl exec -it deployment/authentik-worker -c authentik -- ak ldap_sync *slug of the source*
```

Starting with authentik 2023.10, you can also run command below to explicitly check the connectivity to the configured LDAP Servers:

```
```shell
docker compose run --rm worker ldap_check_connection *slug of the source*
```

or, for Kubernetes, run

```
```shell
kubectl exec -it deployment/authentik-worker -c authentik -- ak ldap_check_connection *slug of the source*
```
6 changes: 3 additions & 3 deletions website/docs/troubleshooting/login.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,19 @@ This recovery key will give whoever has the link direct access to your instances

To create the key, run the following command:

```
```shell
docker compose run --rm server create_recovery_key 10 akadmin
```

For Kubernetes, run

```
```shell
kubectl exec -it deployment/authentik-worker -c authentik -- ak create_recovery_key 10 akadmin
```

or, for CLI, run

```
```shell
ak create_recovery_key 10 akadmin
```

Expand Down
4 changes: 2 additions & 2 deletions website/docs/troubleshooting/missing_admin_group.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ If all of the Admin groups have been deleted, or misconfigured during sync, you

Run the following command, where _username_ is the user you want to add to the newly created group:

```
```shell
docker compose run --rm server create_admin_group username
```

or, for Kubernetes, run

```
```shell
kubectl exec -it deployment/authentik-worker -c authentik -- ak create_admin_group username
```
4 changes: 2 additions & 2 deletions website/docs/troubleshooting/missing_permission.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ The error should be temporary and not occur after initial installation.

If it does, you can run the following command to ensure all permissions exist:

```
```shell
docker compose run --rm worker repair_permissions
```

or, for Kubernetes, run

```
```shell
kubectl exec -it deployment/authentik-worker -c authentik -- ak repair_permissions
```

Expand Down
2 changes: 1 addition & 1 deletion website/docs/user-group-role/user/invitations.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ The fastest way to create an invitation is to use our pre-defined `default-enrol

To download the `default-enrollment-flow` file, run this command:

```
```shell
wget https://goauthentik.io/blueprints/example/flows-enrollment-2-stage.yaml
```

Expand Down
8 changes: 4 additions & 4 deletions website/docs/user-group-role/user/user_ref.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,11 @@ underneath `additionalHeaders`:

#### Example:

```
```yaml
additionalHeaders:
REMOTE-USER: joe.smith
REMOTE-EMAIL: joe@jsmith.com
REMOTE-NAME: Joseph
REMOTE-USER: joe.smith
REMOTE-EMAIL: joe@jsmith.com
REMOTE-NAME: Joseph
```

These headers will now be passed to the application when the user logs in. Most applications will need to be configured to accept these headers. Some examples of applications that can accept additional headers from an authentik Proxy Provider are [Grafana](https://grafana.com/docs/grafana/latest/auth/auth-proxy/) and [Tandoor Recipes](https://docs.tandoor.dev/features/authentication/).
4 changes: 3 additions & 1 deletion website/docusaurus.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const fs = require("fs").promises;
import type { Config } from "@docusaurus/types";
import type * as Preset from "@docusaurus/preset-classic";
import { themes as prismThemes } from "prism-react-renderer";

module.exports = async function (): Promise<Config> {
const remarkGithub = (await import("remark-github")).default;
Expand Down Expand Up @@ -82,6 +82,8 @@ module.exports = async function (): Promise<Config> {
indexName: "goauthentik",
},
prism: {
theme: prismThemes.oneLight,
darkTheme: prismThemes.oneDark,
additionalLanguages: ["python", "diff", "json"],
},
},
Expand Down

0 comments on commit 23ffd98

Please sign in to comment.