Do a large chunk of the move to go
This commit moves a huge chunk of the code to go. The TODO.md document indicates what is left to be done.
This commit is contained in:
parent
db2ad9b4bd
commit
7b38fdd801
93 changed files with 4689 additions and 645 deletions
28
env/stack_self.go
vendored
Normal file
28
env/stack_self.go
vendored
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
package env
|
||||
|
||||
import "github.com/FAU-CDI/wisski-distillery/internal/stack"
|
||||
|
||||
func (dis *Distillery) SelfStack() stack.Installable {
|
||||
TARGET := "https://github.com/FAU-CDI/wisski-distillery"
|
||||
if dis.Config.SelfRedirect != nil {
|
||||
TARGET = dis.Config.SelfRedirect.String()
|
||||
}
|
||||
|
||||
return dis.asCoreStack(stack.Installable{
|
||||
Stack: stack.Stack{
|
||||
Name: "self",
|
||||
},
|
||||
|
||||
EnvFileContext: map[string]string{
|
||||
"VIRTUAL_HOST": dis.DefaultVirtualHost(),
|
||||
"LETSENCRYPT_HOST": dis.DefaultLetsencryptHost(),
|
||||
"LETSENCRYPT_EMAIL": dis.Config.CertbotEmail,
|
||||
"TARGET": TARGET,
|
||||
"OVERRIDES_FILE": dis.Config.SelfOverridesFile,
|
||||
},
|
||||
})
|
||||
}
|
||||
|
||||
func (dis *Distillery) SelfStackPath() string {
|
||||
return dis.SelfStack().Dir
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue