Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Included Unix domain sockets in Reverse proxy - Pomerium #7752

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,15 @@ jenkins:
image: jenkins/jenkins:lts-jdk11
privileged: true
user: root
ports:
- 8080:8080
- 50000:50000

volumes:
# File path to Jenkins_home -- stores configs, build logs, and artifacts
- ./home/jenkins_compose/jenkins_configuration:/var/jenkins_home
# "sock" is the Unix socket the Docker daemon listens on by default
# Unix domain socket
- ./var/run/docker.sock:/var/run/docker.sock
extra_hosts:
# Use Unix domain sockets for Jenkins and Pomerium communication
- "jenkins.local:/var/run/jenkins.sock"

```

Now, run `docker compose up`.
Expand Down Expand Up @@ -123,6 +123,16 @@ routes:
is: example.com
- user:
is: username
- from: https://jenkins.localhost.pomerium.io
to: unix:///var/run/jenkins.sock
pass_identity_headers: true
policy:
- allow:
and:
- domain:
is: example.com
- user:
is: username
```

Next, you need to:
Expand Down Expand Up @@ -153,16 +163,16 @@ version: '3'
networks:
main: {}
services:
pomerium:
image: pomerium/pomerium:latest
volumes:
- ./config.yaml:/pomerium/config.yaml:ro
ports:
- 443:443
networks:
main:
aliases:
- authenticate.localhost.pomerium.io
pomerium:
image: pomerium/pomerium:latest
volumes:
- ./config.yaml:/pomerium/config.yaml:ro
# Mount Unix domain socket
- ./var/run/jenkins.sock:/var/run/jenkins.sock
ports:
- 443:443
networks:
main: {}
verify:
networks:
main: {}
Expand Down
Loading