|
1 |
| -# Podman Mac Client tutorial |
2 |
| - |
3 |
| -## What is the Podman Mac Client |
4 |
| - |
5 |
| -First and foremost, the Mac Client is under heavy development. We are working on getting the |
6 |
| -Mac client to be packaged and run for a native-like experience. This is the setup tutorial |
7 |
| -for the Mac client at its current stage of development and packaging. |
8 |
| - |
9 |
| -The purpose of the Mac client for Podman is to allow users to run Podman on a Mac. Since Podman is a Linux |
10 |
| -container engine, The Mac client is actually a version of the [Podman-remote client](remote_client.md), |
11 |
| -edited to that the client side works on a Mac machine, and connects to a Podman "backend" on a Linux |
12 |
| -machine, virtual or physical. The goal is to have a native-like experience when working with the Mac |
13 |
| -client, so the command line interface of the remote client is exactly the same as the regular Podman |
14 |
| -commands with the exception of some flags and commands that do not apply to the Mac client. |
15 |
| - |
16 |
| -## What you need |
17 |
| - |
18 |
| -To use the Mac client, you will need a binary built for MacOS and a Podman "backend" on a Linux machine; |
19 |
| -hereafter referred to as the Podman node. In this context, a Podman node is a Linux system with Podman |
20 |
| -installed on it and the varlink service activated. You will also need to be able to ssh into this |
21 |
| -system as a user with privileges to the varlink socket (more on this later). |
22 |
| - |
23 |
| -For best results, use the most recent version of MacOS |
24 |
| - |
25 |
| -## Getting the Mac client |
26 |
| -The Mac client is available through [Homebrew](https://brew.sh/). |
27 |
| -``` |
28 |
| -$ brew cask install podman |
29 |
| -``` |
30 |
| - |
31 |
| -## Setting up the client and Podman node connection |
32 |
| - |
33 |
| -To use the Mac client, you must perform some setup on both the Mac and Podman nodes. In this case, |
34 |
| -the Mac node refers to the Mac on which Podman is being run; and the Podman node refers to where |
35 |
| -Podman and its storage reside. |
36 |
| - |
37 |
| -### Connection settings |
38 |
| -Your Linux box must have ssh enabled, and you must copy your Mac's public key from `~/.sconf sh/id.pub` to |
39 |
| -`/root/.ssh/authorized_keys` on your Linux box using `ssh-copy-id` This allows for the use of SSH keys |
40 |
| -for remote access. |
41 |
| - |
42 |
| -You may need to edit your `/etc/ssh/sshd_config` in your Linux machine as follows: |
43 |
| -``` |
44 |
| -PermitRootLogin yes |
45 |
| -``` |
46 |
| - |
47 |
| -Use of SSH keys are strongly encouraged to ensure a secure login. However, if you wish to avoid ‘logging in’ every |
48 |
| -time you run a Podman command, you may edit your `/etc/ssh/sshd_config` on your Linux machine as follows: |
49 |
| -``` |
50 |
| -PasswordAuthentication no |
51 |
| -PermitRootLogin without-password |
52 |
| -``` |
53 |
| - |
54 |
| -### Podman node setup |
55 |
| -The Podman node must be running a Linux distribution that supports Podman and must have Podman (not the Mac |
56 |
| -client) installed. You must also have root access to the node. Check if your system uses systemd: |
57 |
| -``` |
58 |
| -$cat /proc/1/comm |
59 |
| -systemd |
60 |
| -``` |
61 |
| -If it does, then simply start the Podman varlink socket: |
62 |
| -``` |
63 |
| -$ sudo systemctl start io.podman.socket |
64 |
| -$ sudo systemctl enable io.podman.socket |
65 |
| -``` |
66 |
| - |
67 |
| -If your system cannot use systemd, then you can manually establish the varlink socket with the Podman |
68 |
| -command: |
69 |
| -``` |
70 |
| -$ sudo podman --log-level debug varlink --timeout 0 unix://run/podman/io.podman |
71 |
| -``` |
72 |
| - |
73 |
| -### Required permissions |
74 |
| -For now, the Mac client requires that you be able to run a privileged Podman and have privileged ssh |
75 |
| -access to the remote system. This limitation is being worked on. |
76 |
| - |
77 |
| -#### Running the remote client |
78 |
| -There are three different ways to pass connection information into the client: flags, conf file, and |
79 |
| -environment variables. All three require information on username and a remote host ip address. Most often, |
80 |
| -your username should be root and you can obtain your remote-host-ip using `ip addr` |
81 |
| - |
82 |
| -To connect using flags, you can use |
83 |
| -``` |
84 |
| -$ podman --remote-host remote-host-ip --username root images |
85 |
| -REPOSITORY TAG IMAGE ID CREATED SIZE |
86 |
| -quay.io/podman/stable latest 9c1e323be87f 10 days ago 414 MB |
87 |
| -localhost/test latest 4b8c27c343e1 4 weeks ago 253 MB |
88 |
| -k8s.gcr.io/pause 3.1 da86e6ba6ca1 20 months ago 747 kB |
89 |
| -``` |
90 |
| -If the conf file is set up, you may simply use Podman as you would on the linux machine. Take a look at |
91 |
| -[podman-remote.conf.5.md](https://github.com/containers/podman/blob/master/docs/podman-remote.conf.5.md) on how to use the conf file: |
92 |
| - |
93 |
| -``` |
94 |
| -$ podman images |
95 |
| -REPOSITORY TAG IMAGE ID CREATED SIZE |
96 |
| -quay.io/podman/stable latest 9c1e323be87f 10 days ago 414 MB |
97 |
| -localhost/test latest 4b8c27c343e1 4 weeks ago 253 MB |
98 |
| -k8s.gcr.io/pause 3.1 da86e6ba6ca1 20 months ago 747 kB |
99 |
| -``` |
| 1 | +# [Podman Mac Client tutorial](https://github.com/containers/podman/blob/master/docs/tutorials/mac_win_client.md) |
| 2 | +This tutorial has moved! You can find out how to set up Podman on MacOS (as well as Windows) [here](https://github.com/containers/podman/blob/master/docs/tutorials/mac_win_client.md) |
0 commit comments