Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to migrate django/cakephp application #27

Open
stillalearner opened this issue Apr 21, 2022 · 0 comments
Open

Unable to migrate django/cakephp application #27

stillalearner opened this issue Apr 21, 2022 · 0 comments

Comments

@stillalearner
Copy link

I tried to migrate django/cakephp application but facing this issue in kubectl-apply-kustomize step:

STEP-KUBECTL-APPLY

  • '[' true == true ']'
  • export KUBECONFIG=/workspace/kubeconfig/kubeconfig
  • KUBECONFIG=/workspace/kubeconfig/kubeconfig
  • kubectl --context=destination apply -k /workspace/kustomize
    Warning: resource serviceaccounts/builder is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    serviceaccount/builder configured
    Warning: resource serviceaccounts/default is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    serviceaccount/default configured
    Warning: resource serviceaccounts/deployer is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    serviceaccount/deployer configured
    Warning: resource rolebindings/admin is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    rolebinding.authorization.openshift.io/admin configured
    Warning: resource rolebindings/system:deployers is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    rolebinding.authorization.openshift.io/system:deployers configured
    Warning: resource rolebindings/system:image-builders is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    rolebinding.authorization.openshift.io/system:image-builders configured
    Warning: resource rolebindings/system:image-pullers is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    rolebinding.authorization.openshift.io/system:image-pullers configured
    configmap/cakephp-mysql-persistent-1-ca created
    configmap/cakephp-mysql-persistent-1-global-ca created
    configmap/cakephp-mysql-persistent-1-sys-config created
    Warning: resource configmaps/kube-root-ca.crt is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    configmap/kube-root-ca.crt configured
    Warning: resource configmaps/openshift-service-ca.crt is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    configmap/openshift-service-ca.crt configured
    secret/builder-dockercfg-vwfv7 created
    secret/builder-token-f4dql created
    secret/builder-token-nrghv created
    secret/cakephp-mysql-persistent created
    secret/default-dockercfg-jkfkk created
    secret/default-token-95229 created
    secret/default-token-bb84l created
    secret/deployer-dockercfg-szb84 created
    secret/deployer-token-h6ksl created
    secret/deployer-token-pqxgq created
    service/cakephp-mysql-persistent created
    Warning: resource services/mysql is missing the kubectl.kubernetes.io/last-applied-configuration annotation which is required by kubectl apply. kubectl apply should only be used on resources created declaratively by either kubectl create --save-config or kubectl apply. The missing annotation will be patched automatically.
    deploymentconfig.apps.openshift.io/cakephp-mysql-persistent created
    deploymentconfig.apps.openshift.io/mysql created
    buildconfig.build.openshift.io/cakephp-mysql-persistent created
    error validating "/workspace/kustomize": error validating data: [unknown object type "nil" in ImageStreamTag.image.dockerImageMetadata.Created, ValidationError(ImageStreamTag.image): missing required field "dockerImageLayers" in com.github.openshift.api.image.v1.Image, ValidationError(ImageStreamTag): missing required field "tag" in com.github.openshift.api.image.v1.ImageStreamTag]; if you choose to ignore these errors, turn validation off with --validate=false
    Error from server (Invalid): error when applying patch:
    {"metadata":{"annotations":{"description":"Exposes the database server","kubectl.kubernetes.io/last-applied-configuration":"{"apiVersion":"v1","kind":"Service","metadata":{"annotations":{"description":"Exposes the database server","openshift.io/generated-by":"OpenShiftNewApp"},"labels":{"app":"cakephp-mysql-persistent","template":"cakephp-mysql-persistent"},"managedFields":[{"apiVersion":"v1","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:annotations":{".":{},"f:description":{},"f:openshift.io/generated-by":{}},"f:labels":{".":{},"f:app":{},"f:template":{}}},"f:spec":{"f:ports":{".":{},"k:{\"port\":3306,\"protocol\":\"TCP\"}":{".":{},"f:name":{},"f:port":{},"f:protocol":{},"f:targetPort":{}}},"f:selector":{".":{},"f:name":{}},"f:sessionAffinity":{},"f:type":{}}},"manager":"kubectl-create","operation":"Update","time":"2022-04-21T09:59:32Z"}],"name":"mysql","namespace":"cakephptgt"},"spec":{"ports":[{"name":"mysql","port":3306,"protocol":"TCP","targetPort":3306}],"selector":{"name":"mysql"},"sessionAffinity":"None","type":"ClusterIP"}}\n","openshift.io/generated-by":"OpenShiftNewApp"},"labels":{"app":"cakephp-mysql-persistent","template":"cakephp-mysql-persistent"},"managedFields":[{"apiVersion":"v1","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:annotations":{".":{},"f:description":{},"f:openshift.io/generated-by":{}},"f:labels":{".":{},"f:app":{},"f:template":{}}},"f:spec":{"f:ports":{".":{},"k:{"port":3306,"protocol":"TCP"}":{".":{},"f:name":{},"f:port":{},"f:protocol":{},"f:targetPort":{}}},"f:selector":{".":{},"f:name":{}},"f:sessionAffinity":{},"f:type":{}}},"manager":"kubectl-create","operation":"Update","time":"2022-04-21T09:59:32Z"}]},"spec":{"$setElementOrder/ports":[{"port":3306}],"ports":[{"name":"mysql","port":3306,"protocol":"TCP","targetPort":3306}],"selector":{"name":"mysql"}}}
    to:
    Resource: "/v1, Resource=services", GroupVersionKind: "/v1, Kind=Service"
    Name: "mysql", Namespace: "cakephptgt"
    for: "/workspace/kustomize": Service "mysql" is invalid: spec.ports[1].name: Duplicate value: "mysql"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant