Commit a4806cd4 authored by Jürgen Haas's avatar Jürgen Haas

ansible-playbooks/general#96 Avoid restart of some services during updates

parent 54fac553
......@@ -594,6 +594,6 @@
- name: Import needrestart
import_tasks: needrestart.yml
when: ansible_distribution_major_version == '16'
when: ansible_distribution_major_version == '16' or ansible_distribution_major_version == '18'
tags:
- needrestart
......@@ -50,3 +50,12 @@
owner: root
group: root
mode: 0644
- name: Configure Service that should be ignored
template:
src: etc_needrestart_restart_d_ignore.service
dest: /etc/needrestart/restart.d/{{ item }}.service
owner: root
group: root
mode: 0755
with_items: '{{ needrestart_ignore|default([]) }}'
#!/bin/sh
# needrestart - Restart daemons after library updates.
#
# Authors:
# Thomas Liske <thomas@fiasko-nw.net>
#
# Copyright Holder:
# 2013 - 2017 (C) Thomas Liske [http://fiasko-nw.net/~thomas/]
#
# License:
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# enable xtrace if we should be verbose
if [ "$NR_VERBOSE" = '1' ]; then
set -x
fi
echo "Restarting {{ item }} ignored"
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment