-
Notifications
You must be signed in to change notification settings - Fork 474
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
add systemd service files #307
Comments
I feel like |
the latest push creates a pod and put containers in it and passes proper dependencies please test that commit |
for this compose https://github.com/containers/podman-compose/blob/devel/tests/testlogs/docker-compose.yml running
without
|
run
to create now enter your project and type
now at any directory, you can type
|
@tinywrkb your feedback is highly appreciated |
Sorry for the late reply.
|
My bad! Actually
It should be done once. |
For the user service, during run-time (not while packaging), I think it's more appropriate to put the service into |
Or perhaps add a |
Hi :-) The systemd unit files posted here are used by a lot of people. But it has a big problem: Setting I use a small wrapper script:
Service file for completeness:
That's the best I have atm. EDIT: added fix from @alexmaras |
Well..., it's not in any way official, and I'm not affiliated with this project in any way. People should not copy-paste code or config files without understanding how it will affect their system. As I mentioned in my first post when I filed this ticket, these systemd service files are basic, and I can add here and say that I put minimal effort when constructing them.
Maybe switch the service type to |
@yogo1212 your script has an issue - it uses |
We ship systemd unit files
|
@muayyad-alsadi I'm aware, I've tried using them. I hit issues similar to @yogo1212's, so I'm reworking that solution to make it reliable for me. I didn't want someone else to also try that code snippet and hit issues. I'll file a separate issue with some reliability issues I have with the stock systemd unit files. EDIT: Never mind, it looks like my issues will be solved by the default use of |
@alexmaras good point - thank you! |
@muayyad-alsadi The steps provided do not seem to work with the -f flag for providing a different compose file. I have some people using docker and some using podman, and the particular image (localstack) I am doing this for requires different setup for each. I can workaround this by moving files around during setup, but a functional -f flag would be appreciated. |
It would be great if podman-compose could be shipped with systems services files.
I'm attaching my systemd service files. They are pretty basic, probably need to be improved so I'm not adding these myself in a PR, but they are working for me.
/usr/lib/systemd/system/podman-compose@.service
/usr/lib/systemd/user/podman-compose@.service
Previously I was using environment file in
/etc/conf.d
to set the compose file, but now that podman-compose defaults prioritizecompose.yaml
andcompose.yml
, I don't see a reason why we need this configurable.If it's not obvious, each pod should have a folder in
/etc/containers/compose/
and(edit:) or~/.config/containers/compose/
.The text was updated successfully, but these errors were encountered: