acorn-io / runtime

A simple application deployment framework built on Kubernetes

Home Page:https://docs.acorn.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Documentated, but unimplemented feature on deploying to pre-created namespaces feature

fe-ax opened this issue · comments

Related documentation page: https://runtime-docs.acorn.io/running/namespaces-and-service-accounts#to-verify-

This option does not seem to exist, as the following code always generates a name:

func AssignNamespace(req router.Request, resp router.Response) (err error) {
appInstance := req.Object.(*v1.AppInstance)
cond := condition.Setter(appInstance, resp, v1.AppInstanceConditionNamespace)
defer func() {
cond.Error(err)
// clear the error
err = nil
}()
parts := strings.Split(appInstance.Name, ".")
appInstance.Status.Namespace = name.SafeConcatName(parts[len(parts)-1], appInstance.ShortID())
resp.Objects(appInstance)
return nil
}

@fe-ax I ran into this too.

The feature --target-namespace as been removed in v0.8.0 according to the release notes.

The docs page you mentioned is already deleted on the main branch and probably only pending a release.