Last change
on this file was 875, checked in by chronos, 7 years ago |
- Added: Systemd service file.
|
-
Property svn:executable
set to
*
|
File size:
837 bytes
|
Line | |
---|
1 | #!/bin/sh
|
---|
2 | # postrm script for wowpreklad
|
---|
3 |
|
---|
4 | set -e
|
---|
5 |
|
---|
6 | apache_remove() {
|
---|
7 | COMMON_STATE=$(dpkg-query -f '${Status}' -W 'apache2.2-common' 2>/dev/null | awk '{print $3}' || true)
|
---|
8 |
|
---|
9 | if [ -e /usr/share/apache2/apache2-maintscript-helper ] ; then
|
---|
10 | . /usr/share/apache2/apache2-maintscript-helper
|
---|
11 | apache2_invoke disconf wowpreklad
|
---|
12 | elif [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then
|
---|
13 | rm -f /etc/apache2/conf.d/wowpreklad.conf
|
---|
14 | fi
|
---|
15 |
|
---|
16 | rm -f /etc/apache2/conf-available/wowpreklad.conf
|
---|
17 | }
|
---|
18 |
|
---|
19 | service_remove() {
|
---|
20 | if [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then
|
---|
21 | rm -f /etc/systemd/system/wowpreklad.service
|
---|
22 | fi
|
---|
23 | }
|
---|
24 |
|
---|
25 | if [ "$1" = "remove" ] || [ "$1" = "purge" ]; then
|
---|
26 | apache_remove $1
|
---|
27 | service_remove $1
|
---|
28 | fi
|
---|
29 |
|
---|
30 | exit 0
|
---|
Note:
See
TracBrowser
for help on using the repository browser.