Switch from ThirdPartyResources to CustomResourceDefinitions (#381)
Switch Fission's storage over to the new CustomResourceDefinitions, from the deprecated ThirdPartyResources. This allows us to be compatible with Kubernets 1.8 and onwards. This also adds a CLI tool for dumping state from an old fission version and restoring state into new CRDs. The storage service is unaffected by this change.
This commit is contained in:
committed by
Soam Vasani
parent
746c51901d
commit
5f14b9b0ae
@@ -19,21 +19,21 @@ package controller
|
||||
import (
|
||||
"log"
|
||||
|
||||
"github.com/fission/fission/tpr"
|
||||
"github.com/fission/fission/crd"
|
||||
)
|
||||
|
||||
func Start(port int) {
|
||||
fc, kc, err := tpr.MakeFissionClient()
|
||||
fc, _, apiExtClient, err := crd.MakeFissionClient()
|
||||
if err != nil {
|
||||
log.Fatalf("Failed to connect to K8s API: %v", err)
|
||||
}
|
||||
|
||||
err = tpr.EnsureFissionTPRs(kc)
|
||||
err = crd.EnsureFissionCRDs(apiExtClient)
|
||||
if err != nil {
|
||||
log.Fatalf("Failed to create fission TPRs: %v", err)
|
||||
log.Fatalf("Failed to create fission CRDs: %v", err)
|
||||
}
|
||||
|
||||
fc.WaitForTPRs()
|
||||
fc.WaitForCRDs()
|
||||
|
||||
api, err := MakeAPI()
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user