Replies: 3 comments 8 replies
-
Service FragmentsTo change the name of the service, the recommended approach is to override the The problem with the fragment approach is that we need to provide the means for users to add additional services. The only way to achieve this is while still being able to customize the default generated service is to name the service fragment differently for the extra-service. This means that if you provide a service fragment with no name override, then those settings will be merged with the generated service. If however, you provide a service fragment with a different name, this fragment will be accounted for as an extra-service. Local imageYou need to be able to push the image to the cluster's Kubernetes container image registry. Cluster configurationJKube uses the Fabric8 Kubernetes Client to perform the deploy operations. The Kubernetes Client reads your cluster information from your If you don't want to rely on automatic configuration, then you can also provide your cluster configuration https://eclipse.dev/jkube/docs/kubernetes-maven-plugin/#_kubernetes_access_configuration Maybe use 2 different Maven profiles for this so you can switch your cluster just by providing a |
Beta Was this translation helpful? Give feedback.
-
@manusa |
Beta Was this translation helpful? Give feedback.
-
i have uploaded the minimal project. we can excute 'mvn k8s:resorce' which can reproduce the problem , tks. |
Beta Was this translation helpful? Give feedback.
-
then i excute 'mvn k8s:resource', i will get twe service yaml files , one named '${project-name}-service.yml' and the other named 'my-service-service.yml' . Next if i excute 'mvn k8s:deploy' , it will create two services in the k8s cluster , that is not what i expect . i only expect the service with the custom name to be created in the k8s cluster.
after excuting the goal of k8s:build , can i skip the goal of k8s:push and direct deploy the local docker image to the k8s cluster by excuting the goal of k8s:deploy or k8s:apply?
is there any quick way to switch which k8s cluster to deploy to? we need this if we have two or more k8s clusters.
that are all my questions , expect your answer, thanks.
Beta Was this translation helpful? Give feedback.
All reactions