Codebase list debian-goodies / 1a45bbd
checkrestart: Handle the possibility of systemd units in /usr/lib/systemd/system/ Unit 193 2 years ago
1 changed file(s) with 2 addition(s) and 2 deletion(s). Raw diff Collapse all Expand all
284284 continue
285285 package.initscripts.add(path[12:])
286286 # If running on a systemd system, extract the systemd's service files from the package
287 if is_systemd and path.startswith('/lib/systemd/system/') and path.endswith('.service') and path.find('.wants') == -1:
287 if is_systemd and (path.startswith('/lib/systemd/system/') or path.startswith('/usr/lib/systemd/system/')) and path.endswith('.service') and path.find('.wants') == -1:
288288 if path.endswith('@.service'):
289289 continue
290290 # Read the service file and make sure it is not of type 'oneshot'
296296 continue
297297 servicefile.close ()
298298 if not is_oneshot:
299 package.systemdservice.add(path[20:])
299 package.systemdservice.add(os.path.basename(path))
300300 sys.stdout.flush()
301301 dpkgProc.stdout.close()
302302