Skip to content

Commit 8ec769e

Browse files
committed
updates with mkcert steps
1 parent e73834b commit 8ec769e

File tree

4 files changed

+52
-42
lines changed

4 files changed

+52
-42
lines changed
Loading

content/docs/quickstart.mdx

+45-39
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ Welcome to Pomerium! This quickstart shows you how to set up Pomerium Core to pr
3434
**Steps to complete**:
3535

3636
1. Configure [Pomerium Core](/docs/deploy/core) and the [Verify](https://verify.pomerium.com/) web app to run in Docker containers
37-
2. Access the Verify web app behind Pomerium
37+
1. Generate certificates and secrets
38+
1. Access the Verify web app behind Pomerium
3839

3940
**Time to complete:** 5 minutes
4041

@@ -46,7 +47,10 @@ Check out [**Pomerium Fundamentals**](/docs/courses/fundamentals/get-started) fo
4647

4748
## Before you start
4849

49-
This quickstart requires [Docker] and [Docker Compose].
50+
To complete this guide, you need:
51+
52+
- [Docker] and [Docker Compose]
53+
- [mkcert](https://mkcert.dev/)
5054

5155
:::info
5256

@@ -62,73 +66,75 @@ Add the configuration below to `config.yaml`:
6266

6367
<ConfigDocker />
6468

65-
:::caution
69+
### Add a signing key
6670

67-
The `signing_key` above is intended to be used for testing purposes. Do not use this signing key in a production environment.
71+
Pomerium requires a [signing key](/docs/reference/signing-key) to cryptographically sign a user's JWT for identity verification:
6872

69-
See the [**Signing Key**](/docs/reference/signing-key) reference page for instructions on how to generate your own secure signing key.
73+
```bash
74+
openssl ecparam -genkey -name prime256v1 -noout -out ec_private.pem
75+
cat ec_private.pem | base64
76+
```
7077

71-
:::
78+
Replace `signing_key` in `config.yaml` with the ouput of these commands.
7279

73-
## Set up Docker Compose
80+
For example:
7481

75-
Create a `docker-compose.yaml` file in the root of your project.
82+
```yaml title="config.yaml"
83+
signing_key: LS0tLS1CRUdJTiBFQyBQUklWQVRFIEtFWS0tLS0tCk1IY0NBUUVFSUFsSEdxZnFYYzVFTDUwSE1hbUFyOGdJckVYZ0cxaXI5NkQyb1o3aXVxTDlvQW9HQ0NxR1NNNDkKQXdFSG9VUURRZ0FFN0lSWWtFR1k0YjRjRHRvbXlWaVVlL3RrVVlseGZ4SFZLMUx0R0FHWWN0NEcvbTA1TkpBRwpxZWFBRDdmN3pwMEloeGFNRThEdGVoZHNrQXNKNFIxSG1RPT0KLS0tLS1FTkQgRUMgUFJJVkFURSBLRVktLS0tLQo=
84+
```
7685
77-
Add the configuration below to `docker-compose.yaml`:
86+
### Create a wildcard TLS certificate
7887
79-
<DockerCompose />
88+
Generate locally trusted certificates with [mkcert](https://github.com/FiloSottile/mkcert):
8089
81-
## Run Docker Compose
90+
1. Install [mkcert](https://github.com/FiloSottile/mkcert?tab=readme-ov-file#installation)
91+
2. Create a trusted root certificate authority:
8292
8393
```bash
84-
docker compose up
94+
mkcert -install
8595
```
8696

87-
## Access the protected web app
88-
89-
Go to the [Verify URL](https://verify.localhost.pomerium.io) you defined in `config.yaml`.
90-
91-
### Self-signed certificate warning
97+
3. Create a wildcard server certificate for `*.localhost.pomerium.io`:
9298

93-
Because you don't have a valid certificate, Pomerium generates a self-signed one for you. This will prompt your browser to throw a self-signed certificate warning.
99+
```bash
100+
mkcert "*.localhost.pomerium.io"
101+
```
94102

95-
To bypass the warning:
103+
This creates two files in the current working directory:
96104

97-
<Tabs>
98-
<TabItem value="Chrome" label="Chrome">
105+
- `_wildcard.localhost.pomerium.io.pem`
106+
- `_wildcard.localhost.pomerium.io-key.pem`
99107

100-
1. Select **Advanced**
101-
1. Select **Proceed to verify.localhost.pomerium.io (unsafe)**
108+
## Run Pomerium and the Verify application
102109

103-
If you don't see an **Advanced** option:
110+
Create a `docker-compose.yaml` file in the root of your project.
104111

105-
1. Click anywhere in the window
106-
1. Type "thisisunsafe" (no spaces)
107-
1. Make sure **Reload** is selected
108-
1. Select **Enter**
112+
Add the configuration below to `docker-compose.yaml`:
109113

110-
</TabItem>
111-
<TabItem value="Safari" label="Safari">
114+
<DockerCompose />
112115

113-
1. Select **Show Details**
114-
1. Select **visit this website**
115-
1. In the confirmation popup, select **Visit Website**
116+
**Run Docker Compose:**
116117

117-
</TabItem>
118-
<TabItem value="Firefox" label="Firefox">
118+
```bash
119+
docker compose up
120+
```
119121

120-
1. Select **Advanced**
121-
1. Select **Accept the Risk and Continue**
122+
## Access the protected web app
122123

123-
</TabItem>
124-
</Tabs>
124+
Go to the [Verify URL](https://verify.localhost.pomerium.io) you defined in `config.yaml`.
125125

126126
Pomerium will redirect you to our hosted identity provider to authenticate.
127127

128128
Then, it will redirect you to the **Verify** service. You'll see a page like this:
129129

130130
![Accessing the Verify web app behind Pomerium](./img/quickstart/identity-verified.png)
131131

132+
Identity verification was successful!
133+
134+
Let's check the certificate, too:
135+
136+
![Browser showing that the locally trusted domain certificate is valid](./img/quickstart/valid-certificate.png)
137+
132138
Congratulations! You successfully installed Pomerium and accessed your protected web app.
133139

134140
:::caution

content/examples/config/config.docker.yaml.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
```yaml title="config.yaml"
2-
signing_key: LS0tLS1CRUdJTiBFQyBQUklWQVRFIEtFWS0tLS0tCk1IY0NBUUVFSURMV3Q3ZkczV2ZkYjk5elFHQTJObEJXcCt3d0c1aGJoR3MzY29JUlo2SjRvQW9HQ0NxR1NNNDkKQXdFSG9VUURRZ0FFcGtRRktLUUdqcVdzbDlYYkUwWmZLL2ZhbHJ2NENWSWtqSTlydXlCbHdOeDYzNmhZRnBtKwpNM0llTXNUKzRreExidVlZSGZDeUtjQzFnZ1BjSWpCYktRPT0KLS0tLS1FTkQgRUMgUFJJVkFURSBLRVktLS0tLQo=
2+
# Replace signing key
3+
signing_key: <signing_key>
34

45
routes:
56
- from: https://verify.localhost.pomerium.io

content/examples/docker/basic.docker-compose.yml.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
```yaml title="docker-compose.yaml"
2-
version: "3"
32
services:
43
pomerium:
54
image: pomerium/pomerium:latest
65
volumes:
7-
## Mount your config file: https://www.pomerium.com/docs/reference/
6+
## Mount your domain's certificates
7+
- ./_wildcard.localhost.pomerium.io.pem:/pomerium/cert.pem:ro
8+
- ./_wildcard.localhost.pomerium.io-key.pem:/pomerium/privkey.pem:ro
9+
10+
## Mount your config file
811
- ./config.yaml:/pomerium/config.yaml:ro
912
ports:
1013
- 443:443

0 commit comments

Comments
 (0)