feat: add home page
This commit is contained in:
@@ -2,7 +2,6 @@ package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"net"
|
||||
"net/http"
|
||||
@@ -44,7 +43,7 @@ func run(ctx context.Context) {
|
||||
)
|
||||
|
||||
hostKeys := envMust("SSH_HOSTKEYS")
|
||||
files, err := ioutil.ReadDir(hostKeys)
|
||||
files, err := os.ReadDir(hostKeys)
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
@@ -52,6 +51,8 @@ func run(ctx context.Context) {
|
||||
opts = append(opts, ssh.HostKeyFile(filepath.Join(hostKeys, f.Name())))
|
||||
}
|
||||
|
||||
loadTemplates()
|
||||
|
||||
srv := &server{
|
||||
bindHost: envDefault("SSH_HOST", bindHost),
|
||||
domainName: envDefault("SSH_DOMAIN", domainName),
|
||||
|
||||
Reference in New Issue
Block a user