mirror of
https://github.com/kou029w/_.git
synced 2025-02-03 15:48:40 +00:00
Compare commits
3 commits
bf2c96a506
...
c259322b27
Author | SHA1 | Date | |
---|---|---|---|
|
c259322b27 | ||
c8b2ae0f07 | |||
|
e0e122f2a3 |
6 changed files with 41 additions and 3 deletions
5
caddy-md/Caddyfile
Normal file
5
caddy-md/Caddyfile
Normal file
|
@ -0,0 +1,5 @@
|
|||
:8080 {
|
||||
file_server
|
||||
templates
|
||||
try_files {path} /
|
||||
}
|
8
caddy-md/compose.yml
Normal file
8
caddy-md/compose.yml
Normal file
|
@ -0,0 +1,8 @@
|
|||
services:
|
||||
caddy:
|
||||
image: caddy
|
||||
ports:
|
||||
- 8080:8080
|
||||
volumes:
|
||||
- ./Caddyfile:/etc/caddy/Caddyfile
|
||||
- ./srv:/srv
|
1
caddy-md/srv/a.md
Normal file
1
caddy-md/srv/a.md
Normal file
|
@ -0,0 +1 @@
|
|||
# あ
|
15
caddy-md/srv/index.html
Normal file
15
caddy-md/srv/index.html
Normal file
|
@ -0,0 +1,15 @@
|
|||
<!DOCTYPE html>
|
||||
{{- $path := .OriginalReq.URL.Path}}
|
||||
{{- if hasSuffix "/" $path}}{{$path = print $path "index"}}{{end}}
|
||||
{{- $path = print $path ".md"}}
|
||||
{{- if not (fileExists $path)}}{{httpError 404}}{{end}}
|
||||
{{- $markdown := (include $path | splitFrontMatter)}}
|
||||
{{- $title := default (trimSuffix ".md" (base $path)) $markdown.Meta.title}}
|
||||
<html lang="ja">
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width">
|
||||
<title>{{$title}}</title>
|
||||
|
||||
{{markdown $markdown.Body | trim}}
|
||||
|
||||
</html>
|
9
caddy-md/srv/index.md
Normal file
9
caddy-md/srv/index.md
Normal file
|
@ -0,0 +1,9 @@
|
|||
---
|
||||
title: トップ
|
||||
---
|
||||
|
||||
# トップページ
|
||||
|
||||
こんにちは、世界
|
||||
|
||||
- [a](a)
|
|
@ -3560,9 +3560,9 @@ which@^2.0.1, which@^2.0.2:
|
|||
isexe "^2.0.0"
|
||||
|
||||
word-wrap@~1.2.3:
|
||||
version "1.2.3"
|
||||
resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c"
|
||||
integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==
|
||||
version "1.2.5"
|
||||
resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.5.tgz#d2c45c6dd4fbce621a66f136cbe328afd0410b34"
|
||||
integrity sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==
|
||||
|
||||
wrap-ansi@^6.2.0:
|
||||
version "6.2.0"
|
||||
|
|
Loading…
Add table
Reference in a new issue