![](https://seccdn.libravatar.org/avatar/f9a9cf77af20d925b328ee8c95c0068c.jpg?s=120&d=mm&r=g)
On Tue, 19 Jun 2018 12:20:59 +0200 John Paul Adrian Glaubitz <adrian.glaubitz@suse.com> wrote:
On 06/19/2018 12:17 PM, Simon Lees wrote:
I'm not sure how checking if the old service was started / enabled before starting / enabling the new services will cause your package to be unusable by your target audience, you have already stated that they will all have the old service started and enabled.
Can you please explain me how I am supposed to test whether the google-network-daemon service is already running when upgrading from a version which does not include the google-network-daemon service?
Thanks, Adrian
I expect to see code like you have there: if [ -f /usr/lib/systemd/system/google-ip-forwarding-daemon.service ]; then systemctl stop --no-block google-ip-forwarding-daemon systemctl disable google-ip-forwarding-daemon.service FROM_OLD=1 fi if [ -f /usr/lib/systemd/system/google-network-setup.service ]; then systemctl stop --no-block google-network-setup systemctl disable google-network-setup.service FROM_OLD=${FROM_OLD}1 fi if [ "$FROM_OLD" == "11" ] then systemctl enable google-network-daemon.service systemctl start google-network-daemon.service fi so it will enable and start new service only if two that you are replacing was enabled. Josef -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org