mirror of
https://github.com/podman-desktop/podman-desktop
synced 2026-05-24 02:08:24 +00:00
docs: added Using a proxy stories, including using a proxy requiring a custom Certificate Authorities (#1541)
* WIP: docs: Proxy configuration - add configuration if proxy uses a custom CA certificate file fixes https://github.com/containers/podman-desktop/issues/917 Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * Update website/docs/using-podman-desktop-behind-a-proxy/index.md Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * Apply suggestions from code review Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * Update website/docs/using-podman-desktop-behind-a-proxy/index.md Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * docs: addes missing steps Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * docs: added missing step Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * docs: refined procedures, tested on Windows and Linux Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * docs: procedure tested on Windows, and should work on macOS Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * fix: typos Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * fix: frontmatter Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * docs: fix frontmatter, review and fix content Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * fix: typo Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * chore: reformatting Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * Update website/docs/proxy/using-a-proxy-on-linux.md Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> * fix: typo that I cannot fix using GitHub web UI Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com> --------- Signed-off-by: Fabrice Flore-Thébault <ffloreth@redhat.com>
This commit is contained in:
parent
d909cde3fb
commit
c35f3f8e89
5 changed files with 212 additions and 0 deletions
16
website/docs/proxy/index.md
Normal file
16
website/docs/proxy/index.md
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
---
|
||||
sidebar_position: 3
|
||||
title: Using behind a proxy
|
||||
description: Using Podman Desktop behind a proxy requiring custom Certificate Authorities (CA).
|
||||
tags: [podman-desktop, installing, windows, macos, linux]
|
||||
keywords: [podman desktop, containers, podman, installing, installation, windows, macos, linux]
|
||||
---
|
||||
|
||||
# Using Podman Desktop behind a proxy
|
||||
|
||||
You can use Podman Desktop behind a proxy in various situations, such as:
|
||||
|
||||
- [Using a proxy on Windows and macOS](proxy/using-a-proxy)
|
||||
- [Using a proxy requiring a custom Certificate Authorities on macOS and Windows](proxy/using-a-proxy-requiring-a-custom-ca)
|
||||
- [Using a proxy on Linux](proxy/using-a-proxy-on-linux)
|
||||
- [Using a proxy in your containers](proxy/using-a-proxy-in-your-containers.md)
|
||||
41
website/docs/proxy/using-a-proxy-in-your-containers.md
Normal file
41
website/docs/proxy/using-a-proxy-in-your-containers.md
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
---
|
||||
sidebar_position: 3
|
||||
title: In your containers
|
||||
description: Using Podman Desktop behind a proxy requiring custom Certificate Authorities (CA).
|
||||
tags: [podman-desktop, installing, windows, macos, linux]
|
||||
keywords: [podman desktop, containers, podman, installing, installation, windows, macos, linux]
|
||||
---
|
||||
|
||||
# Using a proxy in your containers on macOS and Windows
|
||||
|
||||
You can configure your Podman machine to use a proxy for your containers.
|
||||
|
||||
#### Prerequisites
|
||||
|
||||
- `<your.proxy.tld:port>`: Your proxy URL.
|
||||
|
||||
#### Procedure
|
||||
|
||||
1. Open a shell prompt on the Podman machine:
|
||||
|
||||
```shell-session
|
||||
$ podman machine ssh
|
||||
```
|
||||
|
||||
1. Edit the `containers.conf` file to pass the proxy environment variables to Podman CLI.
|
||||
|
||||
The file location depends on your connection mode:
|
||||
|
||||
- `rootless`: `$HOME/.config/containers/containers.conf`
|
||||
|
||||
- `rootful`: `/etc/containers/containers.conf`
|
||||
|
||||
1. Set the proxy environment variables to pass into the containers:
|
||||
|
||||
```toml
|
||||
[containers]
|
||||
http_proxy = true
|
||||
env = ["http_proxy=<your.proxy.tld:port>", "https_proxy=<your.proxy.tld:port>"]
|
||||
```
|
||||
|
||||
1. Go to **Settings > Resources** and restart the Podman machine.
|
||||
64
website/docs/proxy/using-a-proxy-on-linux.md
Normal file
64
website/docs/proxy/using-a-proxy-on-linux.md
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
---
|
||||
sidebar_position: 4
|
||||
title: Linux
|
||||
description: Using Podman Desktop behind a proxy on Linux.
|
||||
tags: [podman-desktop, proxy, linux]
|
||||
keywords: [podman desktop, containers, podman, proxy, linux]
|
||||
---
|
||||
|
||||
# Using Podman Desktop behind a proxy on Linux
|
||||
|
||||
You can configure Podman to run behind a proxy.
|
||||
|
||||
#### Prerequisites
|
||||
|
||||
- `<proxy_ca.pem>`: Your proxy Certificate Authorities (CA), in Privacy-Enhanced Mail (PEM) format.
|
||||
- `<your.proxy.tld:port>`: Your proxy URL.
|
||||
|
||||
#### Procedure
|
||||
|
||||
1. Edit the `containers.conf` file to pass the proxy environment variables to Podman CLI.
|
||||
|
||||
The file location depends on your connection mode:
|
||||
|
||||
- `rootless`: `$HOME/.config/containers/containers.conf`
|
||||
|
||||
- `rootful`: `/etc/containers/containers.conf`
|
||||
|
||||
1. Set the proxy environment variables to pass into the containers:
|
||||
|
||||
```toml
|
||||
[containers]
|
||||
http_proxy = true
|
||||
env = ["http_proxy=<your.proxy.tld:port>", "https_proxy=<your.proxy.tld:port>"]
|
||||
```
|
||||
|
||||
1. Set the proxy environment variables to pass into the Podman engine:
|
||||
|
||||
```toml
|
||||
[engine]
|
||||
env = ["http_proxy=<your.proxy.tld:port>", "https_proxy=<your.proxy.tld:port>"]
|
||||
```
|
||||
|
||||
1. Add the custom Certificate Authorities (CA) for your proxy:
|
||||
|
||||
```shell-session
|
||||
$ sudo cp <proxy_ca.pem> /etc/pki/ca-trust/source/anchors/
|
||||
$ sudo update-ca-trust
|
||||
```
|
||||
|
||||
1. Restart all `podman` processes.
|
||||
|
||||
```shell-session
|
||||
$ pkill podman
|
||||
```
|
||||
|
||||
1. Restart Podman Desktop: <kbd>Ctrl</kbd> + <kbd>q</kbd>.
|
||||
|
||||
#### Verification
|
||||
|
||||
1. Go to **Images**.
|
||||
1. Click **Pull an image**.
|
||||
1. **Image to Pull**: `bash`
|
||||
1. Click **Pull image**.
|
||||
1. Podman Desktop reports `Download complete`.
|
||||
55
website/docs/proxy/using-a-proxy-requiring-a-custom-ca.md
Normal file
55
website/docs/proxy/using-a-proxy-requiring-a-custom-ca.md
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
---
|
||||
sidebar_position: 2
|
||||
title: Custom Certificate Authorities
|
||||
description: Using Podman Desktop behind a proxy requiring custom Certificate Authorities (CA).
|
||||
tags: [podman-desktop, installing, windows, macos, linux]
|
||||
keywords: [podman desktop, containers, podman, installing, installation, windows, macos, linux]
|
||||
---
|
||||
|
||||
# Using Podman Desktop behind a proxy requiring custom Certificate Authorities (CA) on macOS and Windows
|
||||
|
||||
You can configure Podman Desktop to run behind a proxy requiring custom Certificate Authorities (CA), such as self-signed certificates.
|
||||
The configuration applies to the Podman engine, but not to your containers.
|
||||
|
||||
#### Prerequisites
|
||||
|
||||
- Your proxy URL: `<your.proxy.tld:port>`
|
||||
- Your proxy Certificate Authorities (CA) is stored in your home directory, in the `proxy_ca.pem` file, in Privacy-Enhanced Mail (PEM) format.
|
||||
|
||||
#### Procedure
|
||||
|
||||
1. Go to **Settings > Proxy**, and set your proxy URL:
|
||||
|
||||
1. **Proxy configuration enabled**: yes
|
||||
1. **Web Proxy (HTTP)**: `<your.proxy.tld:port>`
|
||||
1. **Secure Web Proxy (HTTPS)**: `<your.proxy.tld:port>`
|
||||
1. Click the **Update** button
|
||||
|
||||
1. Copy the certificate to the Podman machine:
|
||||
|
||||
```shell-session
|
||||
$ cat proxy_ca.pem | podman machine ssh podman-machine-default "cat > proxy_ca.pem"
|
||||
```
|
||||
|
||||
1. Open a shell prompt on the Podman machine:
|
||||
|
||||
```shell-session
|
||||
$ podman machine ssh podman-machine-default
|
||||
```
|
||||
|
||||
1. Add the custom Certificate Authorities (CA) for your proxy:
|
||||
|
||||
```shell-session
|
||||
$ sudo cp proxy_ca.pem /etc/pki/ca-trust/source/anchors/
|
||||
$ sudo update-ca-trust
|
||||
```
|
||||
|
||||
1. Go to **Settings > Resources** and restart the Podman machine.
|
||||
|
||||
#### Verification
|
||||
|
||||
1. Go to **Images**.
|
||||
1. Click **Pull an image**.
|
||||
1. **Image to Pull**: `bash`
|
||||
1. Click **Pull image**.
|
||||
1. Podman Desktop reports `Download complete`.
|
||||
36
website/docs/proxy/using-a-proxy.md
Normal file
36
website/docs/proxy/using-a-proxy.md
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
---
|
||||
sidebar_position: 1
|
||||
title: macOS and Windows
|
||||
description: Using Podman Desktop behind a proxy on macOS and Windows.
|
||||
tags: [podman-desktop, proxy, windows, macos]
|
||||
keywords: [podman desktop, containers, podman, proxy, windows, macos]
|
||||
---
|
||||
|
||||
# Using Podman Desktop behind a proxy on macOS and Windows
|
||||
|
||||
You can configure Podman Desktop to run behind a proxy.
|
||||
The configuration applies to the Podman engine, but not to your containers.
|
||||
|
||||
#### Prerequisites
|
||||
|
||||
- Your proxy URL: `<your.proxy.tld:port>`.
|
||||
- Your proxy does not require a custom Certificate Authorities. Else see [Using a proxy requiring a custom Certificate Authorities](using-a-proxy-requiring-a-custom-ca).
|
||||
|
||||
#### Procedure
|
||||
|
||||
1. Go to **Settings > Proxy**, and set your proxy URL:
|
||||
|
||||
1. **Proxy configuration enabled**: yes
|
||||
1. **Web Proxy (HTTP)**: `<your.proxy.tld:port>`
|
||||
1. **Secure Web Proxy (HTTPS)**: `<your.proxy.tld:port>`
|
||||
1. Click the **Update** button
|
||||
|
||||
1. Go to **Settings > Resources** and restart the Podman machine.
|
||||
|
||||
#### Verification
|
||||
|
||||
1. Go to **Images**.
|
||||
1. Click **Pull an image**.
|
||||
1. **Image to Pull**: `bash`
|
||||
1. Click **Pull image**.
|
||||
1. Podman Desktop reports `Download complete`.
|
||||
Loading…
Reference in a new issue