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

Deliver podman through a snap #1915

Closed
abitrolly opened this issue Dec 2, 2018 · 40 comments
Closed

Deliver podman through a snap #1915

abitrolly opened this issue Dec 2, 2018 · 40 comments
Assignees
Labels
locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.

Comments

@abitrolly
Copy link
Contributor

[//]: # kind feature

I've just noted that Ubuntu proposes to install docker as a snap. :O

$ docker

Command 'docker' not found, but can be installed with:

sudo snap install docker     # version 18.06.1-ce, or
sudo apt  install docker.io

See 'snap info docker' for additional versions.

I would rather use podman on Ubuntu. It is not available through standard apt repositories. Now if Docker was packages as a snap then it should be possible to pack podman.

Describe the results you expected:
Run build tools with podman to avoid files owned by root in my project directories.

Additional environment details (AWS, VirtualBox, physical, etc.):
https://snapcraft.io/docker

@abitrolly
Copy link
Contributor Author

I started the process - https://github.com/abitrolly/podman - time to work on it is limited, though.

@rhatdan
Copy link
Member

rhatdan commented Dec 3, 2018

@lsm5 Could you look into this?

@lsm5
Copy link
Member

lsm5 commented Jan 11, 2019

hi @abitrolly thanks for filing this. I did notice that you had registered podman on the snap store. Just wanted to check if you have prior work already toward this that we could use.

@lsm5
Copy link
Member

lsm5 commented Jan 11, 2019

I started the process - https://github.com/abitrolly/podman - time to work on it is limited, though.

errr sorry I should've read this before posting prior comment. I'll use this and credit you :) . If it can be upstreamed into default libpod, I'll let you know about that.

@lsm5 lsm5 self-assigned this Jan 11, 2019
@abitrolly
Copy link
Contributor Author

abitrolly commented Jan 13, 2019 via email

@rhatdan
Copy link
Member

rhatdan commented Jan 14, 2019

@abitrolly What do you want from an SELinux point of view? Podman to check if :Z and :z is not supplied and the mount point is not read/only then check if the label of the mount point is not container_file_t? Print a warning?

@abitrolly
Copy link
Contributor Author

abitrolly commented Jan 15, 2019 via email

@rhatdan
Copy link
Member

rhatdan commented Mar 8, 2019

Podman is available via a snap now.

@rhatdan rhatdan closed this as completed Mar 8, 2019
@abitrolly
Copy link
Contributor Author

@rhatdan I can't find it anymore - https://snapcraft.io/search?q=podman - do you have a link?

@rhatdan
Copy link
Member

rhatdan commented Apr 7, 2019

@lsm5 ^^

@lsm5
Copy link
Member

lsm5 commented Apr 8, 2019

Podman is available via a snap now.

Unlikely, I have the podman name registered on the snap store and I haven't had the time to publish it yet. Unless someone stole it from me and published it.

@lsm5 lsm5 reopened this Apr 8, 2019
@abitrolly
Copy link
Contributor Author

@lsm5does it work? What is required to push it to the --edge channel?

@lsm5
Copy link
Member

lsm5 commented Apr 23, 2019

well I'm still working on the skopeo snap, which will be needed before I can get podman done.

@abitrolly
Copy link
Contributor Author

abitrolly commented Apr 24, 2019

@lsm5 let me know if you need help with packing. I've set a pipeline to build and push snaps from Travis CI - https://github.com/yakshaveinc/linux. It fails right now, but if you need that component, I can try to allocate some time/money to get this done.

@abitrolly
Copy link
Contributor Author

@lsm5 did you manage to snap the skopeo to switch to podman?

@rhatdan
Copy link
Member

rhatdan commented Aug 5, 2019

@lsm5 Any movement on this? @abitrolly Interested in helping?

@lsm5
Copy link
Member

lsm5 commented Aug 5, 2019 via email

@abitrolly
Copy link
Contributor Author

@rnatdan I started the process in https://github.com/abitrolly/podman then Ubuntu staff asked me to hand over the name on official request, so I hoped that you do this. :D

I am interested, but not in my free time as I now use Fedora and there are too many warning about snap with SELinux to use it there.

@lsm5
Copy link
Member

lsm5 commented Aug 7, 2019

@rnatdan I started the process in https://github.com/abitrolly/podman then Ubuntu staff asked me to hand over the name on official request, so I hoped that you do this. :D

Hey, sorry, I guess I was behind nagging ubuntu staff, but then I had a lot of distractions come my way so couldn't get this in.

I am interested, but not in my free time as I now use Fedora and there are too many warning about snap with SELinux to use it there.

Glad to hear you use Fedora :) . @mikeroyal would you be interested in continuing @abitrolly's snap work for podman as well?

@abitrolly
Copy link
Contributor Author

I didn't do much work there - forking the checklist, placing logos, filling boilerplate. There is already https://snapcraft.io/docs/docker-support-interface and there might be specific hacks that are needed on a system level. https://github.com/abitrolly/podman though is a good start and I would be happy to move it to this organization to collaborate.

@rhatdan
Copy link
Member

rhatdan commented Aug 8, 2019

Getting podman into snap is critical, either open a PR to get this into github.com/libpod, or should we look for others?

@abitrolly
Copy link
Contributor Author

@rhatdan just fork https://github.com/abitrolly/podman under the name like https://github.com/libpod/snapcraft and I will be able to submit PRs so that we can setup CI.

@rhatdan
Copy link
Member

rhatdan commented Aug 9, 2019

Could you open a PR to add this, then we can get it merged and let you fix it. :^)

@haircommander
Copy link
Collaborator

I just did it @rhatdan @abitrolly

@mikeroyal
Copy link

Hi @lsm5, I can help you guys out. 👍

@rhatdan
Copy link
Member

rhatdan commented Aug 12, 2019

Thanks @mikeroyal

@cevich
Copy link
Member

cevich commented Sep 23, 2019

Fix is in #3969

@cevich
Copy link
Member

cevich commented Sep 23, 2019

Monitoring for post-merge success:
https://cirrus-ci.com/build/6163886895529984

@cevich
Copy link
Member

cevich commented Sep 23, 2019

There's some (unknown/unexpected) problem with #3969 post-merge. I do not see the new 'upload_snap` task being scheduled (link above). However, looking under one of the running tasks, I can verify that indeed:

CIRRUS_BRANCH=master
...
DEST_BRANCH=master

So the execution condition is met for the task. Investigating...

@cevich
Copy link
Member

cevich commented Sep 23, 2019

...I believe this is a bug in Cirrus-CI. I've contacted their support about this and to confirm.

@cevich
Copy link
Member

cevich commented Sep 23, 2019

@abitrolly FYI ^^^^^^

@abitrolly
Copy link
Contributor Author

I've just commented about the same in the fixing PR. Nice to see somebody contacted Cirrus CI already. :D

@cevich
Copy link
Member

cevich commented Sep 24, 2019

Update: I know this is a bug/limitation in Cirrus-CI (proven via another PR). The issue is all instances of

    only_if: $CIRRUS_BRANCH != $DEST_BRANCH

and

    only_if: $CIRRUS_BRANCH == $DEST_BRANCH

Will not resolve the RHS. I'm not excited about substituting the branch name for every one, since it adds confusing duplication and will break when future branches/forks are created 😖

i.e. the reason why having $DEST_BRANCH is helpful 🤕

So let's wait a bit to see what their support says.

@rhatdan
Copy link
Member

rhatdan commented Sep 27, 2019

@cevich is this ready to merge?

@cevich
Copy link
Member

cevich commented Sep 27, 2019

Thanks for the mention, I was just looking for this issue but couldn't find it. I followed up this morning and got a reply straight away from Cirrus: The only_if bug has been fixed.

I'm watching merges to master to confirm the snap pushing task fires as it should...

@cevich
Copy link
Member

cevich commented Sep 27, 2019

...okay, I see the upload task here on this post-merge build: https://cirrus-ci.com/build/5739016533573632 so the Cirrus-CI bug is fixed. Now to see if the upload works...

@cevich
Copy link
Member

cevich commented Sep 27, 2019

...Oh gosh 615M of packages to install for both test_build_snap and upload_snap, that's ripe for some optimization, even if just to make it rely less on the network/repositories...

@cevich
Copy link
Member

cevich commented Sep 27, 2019

Pushing 'podman_0.11.1.1_amd64.snap'

Hrmmm....well that could be a problem 😄

@cevich
Copy link
Member

cevich commented Sep 27, 2019

Okay, the intent is functional.

Get it from the Snap Store

@cevich cevich closed this as completed Sep 27, 2019
@abitrolly
Copy link
Contributor Author

Well, it is possible to beef up Docker image a bit to pre-cache binutils and other compiler tools.

@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 23, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
Development

No branches or pull requests

6 participants