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

[Question] How do you use Ansible Podman collection and where? What is important for you? #470

Open
sshnaidm opened this issue Sep 2, 2022 · 9 comments

Comments

@sshnaidm
Copy link
Member

sshnaidm commented Sep 2, 2022

Hello to all users of Ansible Podman collection.
For better prioritization of features and tasks I'd like to know:

  • How you use this collection
  • Which modules of it are most useful for you
  • Which companies use it
  • What features you are interested in.

Please tell as much details as you're comfortable with.
All that will help me to understand the audience better and to keep the collection viable and meaningful.
I'm open to any feedback, but keep in mind I'm doing this mostly in my free time and all contributions are always welcome!
Thanks for your replies in advance.

@sshnaidm sshnaidm pinned this issue Sep 2, 2022
@zhan9san
Copy link

zhan9san commented Sep 2, 2022

Thanks for your time and great work.

How you use this collection

We use Ansible Podman collection in molecule-podman in our CI jobs. We are running a Jenkins instance with Kubernetes cluster with docker runtime.

Instead of Docker-out-of-Docker, we use Podman-in-Docker, and then molecule will discover local Podman images/network and create Podman network
Reference: https://github.com/ansible-community/molecule-podman/blob/main/src/molecule_podman/playbooks/create.yml

Which modules of it are most useful for you

  1. containers.podman.podman_image_info
  2. containers.podman.podman_network_info
  3. containers.podman.podman_network

@thibaultamartin
Copy link

Thanks for all the efforts you're putting in this great collection which has already been incredibly useful to me.

How you use this collection

I use this collection in two ways mostly:

  • To handle my personal infra. This collection allows me to create pods and containers, and run them as services
  • To create easy-to-reproduce test environments people can use to test destructive or impactful commands. This is useful for people who want a quick development environment they can develop scripts against.

Which modules of it are most useful for you

podman_container and podman_pod by far, though I'm going to explore podman_secret shortly

Which companies use it

I'm using it for my personal infrastructure, and I use it with my Element hat on to create the easy to reproduce environments mentioned above.

What features you are interested in.

I'm mostly interested in better support for dependent containers (when a container require another in a pod). That means both being able to update without Ansible telling me one depends on the other (see #374), and better support in the systemd generated files (should be fixed in next release by #432)

@marvin-sinister
Copy link

Hi, thanks for the effort.

How you use this collection

I use it both for my personal infra and for our clients. It's used to make repeatable deployments of either single containers or pods with multiple containers.
In any environment that doesn't warrant k8s for any reason this is my preferred way to schedule container workload.

Which modules of it are most useful for you

podman_container and podman_pod but also using podman_image and podman_image_info

What features you are interested in.

Now that podman_unshare is merged, stability and bug fixes is what is most exciting for my use cases.

@exploide
Copy link
Contributor

exploide commented Oct 2, 2022

I'm using Ansible to setup the infrastructure I operate. With ansible-podman-collections I try to containerize some services.

Therefore, I use podman_pod and podman_container the most to create the Podman objects. Then a task with generate_systemd is necessary to persist the definition to service units, which can be enabled and started afterwards.

That means for me, the proper functioning of generate_systemd with idempotence and all this is important.

@fsdrw08
Copy link

fsdrw08 commented Feb 16, 2023

I use containers.podman.podman_play and containers.podman.podman_generate_systemd to create pod and generate systemd service unit file for development env deployment purpose

@michaeloa
Copy link

We use ansible for practically everything, and have been trying to setup rootless pods using podman for some time now. Not succeding very well, though; firstly the ansible command puts container and network files into /tmp/ (really doesn't seem like such a good idea), and secondly, the pods are just not stable. So right now we're not finding the collection useful at all.

@ivanov17
Copy link

ivanov17 commented Aug 30, 2023

@sshnaidm thank you so much for your work! I love Podman and Ansible, and have been using this collection for a long time. I use most of the existing modules in the collection, currently excluding the podman_import/podman_export, podman_save/podman_load, podman_play, podman_tag and podman_containers modules.

The most important for me are the podman_container, podman_network, podman_pod, podman_image, podman_volume and related *_info modules. The podman_generate_systemd and podman_secret modules are also very useful.

I use this collection for my pet project to manage a group of machines running CentOS Stream. Many of my ansible roles are for running various applications using Podman containers. So this collection helps me a lot.

I think the collection is more stable now than it was three years ago. Of course, there are some bugs, such as non-idempotent behavior when ports are bound to the address 0.0.0.0, but this is not critical for me.

I would like to see a module for udica utility in the collection. I'm currently using several steps to get information about the containers in a pod, then create policies and parse the output to get the shell commands I should apply. If I had a ready-made module it would be a little easier and wouldn't break idempotency. But it may be necessary to work on improving udica as well.

Also I want to see more options for the build dictionary in the podman_image module, like labels.

@sshnaidm
Copy link
Member Author

@ivanov17 thanks for feedback! Can you please create issues for support of udica and idempotency bug? podman_image is far from being ideal unfortunately, I'd like to rewrite it completely, although it's fine to update it with all required parameters now. Feel free to submit issues!

@ivanov17
Copy link

ivanov17 commented Sep 5, 2023

@sshnaidm thank you very much! I'll create issues later, I need to first check for an idempotency bug on the latest version of the collection and think about what I can propose to implement in the udica module(s).

udica can work not only with podman containers, but also with docker, kubectl and so on. Is it worth implementing all this in the collection? Also, it seems better to have two separate modules for podman that can work with pods and containers. It would be nice to start with some structure.

I think next week I'll try to describe all this in more detail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants