[GH-ISSUE #2951] ollama upgrade request: take care of systemd service setup #63850

Closed
opened 2026-05-03 15:11:47 -05:00 by GiteaMirror · 1 comment
Owner

Originally created by @kedar-1 on GitHub (Mar 6, 2024).
Original GitHub issue: https://github.com/ollama/ollama/issues/2951

Hello,

I have modified /etc/systemd/system/ollama.service file to listen on all interfaces:
Environment="OLLAMA_HOST=0.0.0.0"

Works as expected but after every upgrade I must open the file and insert this config option again.

Is there any way to allow upgrade of ollama and take care of already defined systemd service setup?

Thanks

Originally created by @kedar-1 on GitHub (Mar 6, 2024). Original GitHub issue: https://github.com/ollama/ollama/issues/2951 Hello, I have modified /etc/systemd/system/ollama.service file to listen on all interfaces: Environment="OLLAMA_HOST=0.0.0.0" Works as expected but after every upgrade I must open the file and insert this config option again. Is there any way to allow upgrade of ollama and take care of already defined systemd service setup? Thanks
Author
Owner

@mxyng commented on GitHub (Mar 6, 2024):

The best way to modify systemd services is to create an override configuration under /etc/systemd/system/<service>.d/<configuration>.conf. This separation allows the user customization of systemd configurations while allows the vendor to modify the base configuration.

For more details, see the FAQ

<!-- gh-comment-id:1981900088 --> @mxyng commented on GitHub (Mar 6, 2024): The best way to modify systemd services is to create an override configuration under `/etc/systemd/system/<service>.d/<configuration>.conf`. This separation allows the user customization of systemd configurations while allows the vendor to modify the base configuration. For more details, see the [FAQ](https://github.com/ollama/ollama/blob/main/docs/faq.md#setting-environment-variables-on-linux)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#63850