28 lines
413 B
Go
28 lines
413 B
Go
|
package controllers
|
||
|
|
||
|
import (
|
||
|
"context"
|
||
|
"log"
|
||
|
|
||
|
ctrl "sigs.k8s.io/controller-runtime"
|
||
|
)
|
||
|
|
||
|
type Environemnt struct {
|
||
|
Controller ctrl.Manager
|
||
|
Data *EnvironemntData
|
||
|
}
|
||
|
|
||
|
type EnvironemntData struct {
|
||
|
Name string
|
||
|
Provider string
|
||
|
}
|
||
|
|
||
|
func (env *Environemnt) Create(ctx context.Context) error {
|
||
|
log.Printf("%s", env.Data.Name)
|
||
|
log.Printf("%s", env.Data.Provider)
|
||
|
|
||
|
// Create a configmap
|
||
|
//
|
||
|
return nil
|
||
|
}
|