SSH TEstg

This commit is contained in:
Kekskurse 2022-01-15 00:21:02 +01:00
parent 2aada6342c
commit e1307d17ca
Signed by: kekskurse
GPG key ID: 728ACCB59341E7E4
2 changed files with 18 additions and 2 deletions

View file

@ -14,4 +14,15 @@ steps:
repo: kekskurse/kuvia repo: kekskurse/kuvia
username: kekskurse username: kekskurse
password: password:
from_secret: docker_password from_secret: docker_password
- name: ssh commands
image: appleboy/drone-ssh
settings:
host: green.keks.cloud
username: kekskurse
port: 65223
key:
from_secret: ssh_key
script:
- echo hello
- echo world

View file

@ -22,6 +22,7 @@ import (
"kuvia/pkg/globaleuserdata" "kuvia/pkg/globaleuserdata"
"net/http" "net/http"
"os" "os"
"strconv"
) )
//go:embed public //go:embed public
@ -117,9 +118,13 @@ func main() {
}, },
)) ))
redisDB, err := strconv.Atoi(os.Getenv("REDIS_DB"))
if err != nil {
log.Fatal().Err(err).Str("Redis DB String", os.Getenv("REDIS_DB")).Msg("Cant convertz Redis DB to int")
}
ro := redis.Options{ ro := redis.Options{
Addr: os.Getenv("REDIS_HORST"), Addr: os.Getenv("REDIS_HORST"),
DB: os.Getenv("REDIS_DB").(int), DB: redisDB,
} }
f.Use(session.Sessioner(session.Options{ f.Use(session.Sessioner(session.Options{
Initer: sredis.Initer(), Initer: sredis.Initer(),