监视 RC 和相对路径

发布于 2025-01-15 21:25:43 字数 451 浏览 3 评论 0原文

在Monit中,实际上可以使用相对路径吗?当我使用非绝对路径时,我会遇到语法错误。

因此,当 monit -c etc/monitrc -t 给出以下配置的良好语法状态时,

set httpd
     port 2812
     with ssl {
        pemchain: /Users/asdf/src/example-django/etc/ssl/certs/monit.chain.pem
        pemkey: /Users/asdf/src/example-django/etc/ssl/certs/monit.key.pem
        SELFSIGNED: ALLOW

     }
     allow myuser:mypassword

如果将其更改为相对路径,我会收到语法错误: 语法错误 'etc/ssl/certs /monit.chain.pem'。

In Monit, is it actually possible to use relative paths? When I use non-absolute paths I get syntax errors.

So when monit -c etc/monitrc -t gives an ok syntax status wih the following config

set httpd
     port 2812
     with ssl {
        pemchain: /Users/asdf/src/example-django/etc/ssl/certs/monit.chain.pem
        pemkey: /Users/asdf/src/example-django/etc/ssl/certs/monit.key.pem
        SELFSIGNED: ALLOW

     }
     allow myuser:mypassword

I get an syntax error if I change it to relative paths: syntax error 'etc/ssl/certs/monit.chain.pem'.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

維他命╮ 2025-01-22 21:25:43

在 Monit 中,使用文件的绝对路径。有关更多信息,请参阅手册,https://mmonit.com/monit/documentation /monit.html

In Monit, the absolute path to the file is used. For some more information have a look to the manual, https://mmonit.com/monit/documentation/monit.html

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文