diff options
author | Matt Holt <mholt@users.noreply.github.com> | 2020-03-13 11:06:08 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-13 11:06:08 -0600 |
commit | 5a19db5dc2db7c02d0f99630a07a64cacb7f7b44 (patch) | |
tree | d820ee2920d97d7cf2faf0fd9541156e20c88d60 /replacer.go | |
parent | cfe85a9fe625fea55dc4f809fd91b5c061064508 (diff) |
v2: Implement 'pki' app powered by Smallstep for localhost certificates (#3125)
* pki: Initial commit of PKI app (WIP) (see #2502 and #3021)
* pki: Ability to use root/intermediates, and sign with root
* pki: Fix benign misnamings left over from copy+paste
* pki: Only install root if not already trusted
* Make HTTPS port the default; all names use auto-HTTPS; bug fixes
* Fix build - what happened to our CI tests??
* Fix go.mod
Diffstat (limited to 'replacer.go')
-rw-r--r-- | replacer.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/replacer.go b/replacer.go index d1c58e8..4ff578c 100644 --- a/replacer.go +++ b/replacer.go @@ -19,6 +19,7 @@ import ( "os" "path/filepath" "runtime" + "strconv" "strings" "time" ) @@ -236,6 +237,8 @@ func globalDefaultReplacements(key string) (string, bool) { return runtime.GOARCH, true case "time.now.common_log": return nowFunc().Format("02/Jan/2006:15:04:05 -0700"), true + case "time.now.year": + return strconv.Itoa(nowFunc().Year()), true } return "", false |