]> git.proxmox.com Git - mirror_zfs-debian.git/blob - debian/patches/init-debian-openrc-workaround.patch
forwarded patch to upstream.
[mirror_zfs-debian.git] / debian / patches / init-debian-openrc-workaround.patch
1 Description: Make these scripts work for Debian+OpenRC setup.
2 Author: Mo Zhou <lumin@debian.org>
3 Last-update: 20181026
4 Forward: https://github.com/zfsonlinux/zfs/issues/8063
5
6 diff --git a/etc/init.d/zfs-import.in b/etc/init.d/zfs-import.in
7 index fea661bb..404af82d 100644
8 --- a/etc/init.d/zfs-import.in
9 +++ b/etc/init.d/zfs-import.in
10 @@ -1,4 +1,4 @@
11 -#!@SHELL@
12 +#!/bin/sh
13 #
14 # zfs-import This script will import ZFS pools
15 #
16 @@ -308,8 +308,6 @@ do_start()
17
18 # ----------------------------------------------------
19
20 -if [ ! -e /sbin/openrc-run ]
21 -then
22 case "$1" in
23 start)
24 do_start
25 @@ -331,9 +329,3 @@ then
26 esac
27
28 exit $?
29 -else
30 - # Create wrapper functions since Gentoo don't use the case part.
31 - depend() { do_depend; }
32 - start() { do_start; }
33 - status() { do_status; }
34 -fi
35 diff --git a/etc/init.d/zfs-mount.in b/etc/init.d/zfs-mount.in
36 index fa954e09..b6a3de9b 100644
37 --- a/etc/init.d/zfs-mount.in
38 +++ b/etc/init.d/zfs-mount.in
39 @@ -1,4 +1,4 @@
40 -#!@SHELL@
41 +#!/bin/sh
42 #
43 # zfs-mount This script will mount/umount the zfs filesystems.
44 #
45 @@ -199,8 +199,6 @@ do_stop()
46
47 # ----------------------------------------------------
48
49 -if [ ! -e /sbin/openrc-run ]
50 -then
51 case "$1" in
52 start)
53 do_start
54 @@ -219,9 +217,3 @@ then
55 esac
56
57 exit $?
58 -else
59 - # Create wrapper functions since Gentoo don't use the case part.
60 - depend() { do_depend; }
61 - start() { do_start; }
62 - stop() { do_stop; }
63 -fi
64 diff --git a/etc/init.d/zfs-share.in b/etc/init.d/zfs-share.in
65 index ce3cc1cc..0b14f481 100644
66 --- a/etc/init.d/zfs-share.in
67 +++ b/etc/init.d/zfs-share.in
68 @@ -1,4 +1,4 @@
69 -#!@SHELL@
70 +#!/bin/sh
71 #
72 # zfs-share This script will network share zfs filesystems and volumes.
73 #
74 @@ -58,7 +58,6 @@ do_stop()
75
76 # ----------------------------------------------------
77
78 -if [ ! -e /sbin/openrc-run ]; then
79 case "$1" in
80 start)
81 do_start
82 @@ -77,9 +76,3 @@ if [ ! -e /sbin/openrc-run ]; then
83 esac
84
85 exit $?
86 -else
87 - # Create wrapper functions since Gentoo don't use the case part.
88 - depend() { do_depend; }
89 - start() { do_start; }
90 - stop() { do_stop; }
91 -fi
92 diff --git a/etc/init.d/zfs-zed.in b/etc/init.d/zfs-zed.in
93 index d0086eef..4798105d 100644
94 --- a/etc/init.d/zfs-zed.in
95 +++ b/etc/init.d/zfs-zed.in
96 @@ -1,4 +1,4 @@
97 -#!@SHELL@
98 +#!/bin/sh
99 #
100 # zfs-zed
101 #
102 @@ -98,7 +98,6 @@ do_reload()
103
104 # ----------------------------------------------------
105
106 -if [ ! -e /sbin/openrc-run ]; then
107 case "$1" in
108 start)
109 do_start
110 @@ -124,11 +123,3 @@ if [ ! -e /sbin/openrc-run ]; then
111 esac
112
113 exit $?
114 -else
115 - # Create wrapper functions since Gentoo don't use the case part.
116 - depend() { do_depend; }
117 - start() { do_start; }
118 - stop() { do_stop; }
119 - status() { do_status; }
120 - reload() { do_reload; }
121 -fi