abiosoft / abiosoft/caddy-git

How to reload caddy after fetching git repo?

未關閉
#59 4 則留言 2 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
Go
星號
206
分支
42
PR 合併指標
30 天內沒有已合併 PR

描述

There might be many reasons to reload caddy after updating git repo.

In my case I use `markdown` and `templates` with markdown directive. Example:

```
localhost {
root /var/www/html

git {
repo myrepo.git
path /var/caddy-repo
then rsync -a --delete --force --update /var/caddy-repos/content/ /var/www/html
}

ext .md

markdown / {
template templates/default.html
template nice templates/nice.html
}

}
```

When I update `content/templates/nice.html`, without reloading caddy it won't update the template file.

But if I add `then sudo systemctl reload caddy` to `Caddyfile`, it gets trapped to `reload` and `git fetch` loop.

Is it possible to internally somehow reload configuration? Or is it an issue of `markdown` directive?

貢獻指南

這個儲存庫沒有索引到貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。