Skip to content

Commit 9ae746b

Browse files
committed
MG-359 pointing to const
1 parent 693a0ab commit 9ae746b

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

src/github.com/mageddo/dns-proxy-server/service/service.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,14 +99,14 @@ func (sc *Service) Uninstall() error {
9999
sc.logger.Infof("status=begin")
100100
var err error
101101

102-
if out, err, _ := utils.Exec("service", "dns-proxy-server", "stop"); err != nil {
102+
if out, err, _ := utils.Exec("service", DNS_PROXY_SERVER_SERVICE, "stop"); err != nil {
103103
sc.logger.Infof("status=stop-fail, msg=maibe-no-running, out=%s", string(out))
104104
}
105105

106106
if utils.Exists("update-rc.d") {
107-
_, err, _ = utils.Exec("update-rc.d", "-f", "dns-proxy-server", "remove")
107+
_, err, _ = utils.Exec("update-rc.d", "-f", DNS_PROXY_SERVER_SERVICE, "remove")
108108
} else if utils.Exists("chkconfig") {
109-
_, err, _ = utils.Exec("chkconfig", "dns-proxy-server", "off")
109+
_, err, _ = utils.Exec("chkconfig", DNS_PROXY_SERVER_SERVICE, "off")
110110
} else {
111111
sc.logger.Warningf("status=impossible to remove service")
112112
}

src/github.com/mageddo/dns-proxy-server/utils/env/env.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,4 @@ package env
44
const (
55
MG_WORK_DIR = "MG_WORK_DIR"
66
MG_RESOLVCONF = "MG_RESOLVCONF"
7-
MG_SERVICE_PATH = "MG_SERVICE_PATH"
87
)

0 commit comments

Comments
 (0)