-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[NO TESTS NEEDED] Disable docker and alias to podman in FCOS ignition #11703
[NO TESTS NEEDED] Disable docker and alias to podman in FCOS ignition #11703
Conversation
/approve |
LGTM |
Any reason to not link docker.sock -> podman.sock? |
/lgtm If we want the link, that seems like a reasonable followon PR |
Do we really want an overlay fs over |
I assumed it wouldn't, but this could be a faulty assumption. I'll see if I can check (unless someone else who knows FCOS better than me knows off the top of their head). The overlay is the only way I know of to do this without relying on a custom FCOS build, since it's part of the base stream and the FS is read-only. I assume we don't want to go the route of a custom build since it would require maintaining a new stream. |
Actually, I might also be able to do this with overrides and just pull the package. |
Spoke with FCOS devs if they had any other suggestions: They don't have a great solution to this problem, but do plan to address it in the future. The following options exist today
I'll do a revision that goes with approach 3. BTW I also asked about filesystem conventions, and both /opt and /usr/local are linked from var, so within policy. |
a9aaa80
to
f4d745f
Compare
f4d745f
to
7039862
Compare
done
and done :) |
LGTM |
@baude @Luap99 @dustymabe PTAL |
LGTM, but definitely want a head nod from one or more of the folks @rhatdan called out. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
requested a few changes. As mentioned you'll need to use systemd-tmpfiles for the socket symlink. Here's the butane config I was using recently when testing this:
variant: fcos
version: 1.3.0
storage:
files:
- path: /etc/tmpfiles.d/podman-docker.conf
mode: 0644
contents:
inline: |
# Create a symlink from the docker socket to the podman socket.
# Taken from https://github.com/containers/podman/blob/main/contrib/systemd/system/podman-docker.conf
L+ /run/docker.sock - - - - /run/podman/podman.sock
systemd:
units:
- name: docker.service
enabled: false
mask: true
- name: docker.socket
enabled: false
mask: true
- name: podman.socket
enabled: true
50cabb0
to
755eff8
Compare
755eff8
to
387ec0f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some requested changes.. Also do we need to explicitly enable podman.socket
? At least on my system it's not enabled (but my system is an old system).
Signed-off-by: Jason Greene <[email protected]> Co-authored-by: Dusty Mabe <[email protected]>
b912a46
to
b3307bc
Compare
Thanks @dustymabe, applied those. Podman sock is already enabled here: podman/pkg/machine/ignition.go Line 115 in b3307bc
|
After=network-online.target | ||
Wants=network-online.target podman.socket |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not necessarily for this PR, but note that network-online.target
doesn't work for user units.. See
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: baude, dustymabe, n1hility The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/lgtm |
This PR disables the docker.sock systemd unit and sets up an overlay to replace /usr/bin/docker with a symlink to podman as discussed in [1]. A future PR will add support for dial-stdio, which would result in docker compatibility for those using docker cli ssh connections (not the local proxy/forwarding approach which is handled differently).
[1] #11643 (comment)
[NO TESTS NEEDED] since this is specific to podman machine(no testing infra yet)
Signed-off-by: Jason Greene [email protected]