-
Notifications
You must be signed in to change notification settings - Fork 714
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
Kubeadm does not provide mount point for scheduler policy-config-file #518
Comments
This issue if resolved by https://github.com/kubernetes/kubernetes See discussion: #484 |
Does it require any other config to be used in the kubeadm-config.yaml ?? |
The scheduler container yaml still does not contain the additional volume mount: spec:
|
After providing the below configuration in the kubeadm config file: schedulerExtraVolumes:
The below kube-scheduler.yaml got created, however kubeadm is not able to start the kube-scheduler apiVersion: v1
|
Making the below changes to the kubeadm config file:
Made the kube-scheduler to be scheduled successfully. |
Is this a BUG REPORT
Choose one: BUG REPORT
Versions
kubeadm version (use
kubeadm version
): 1.8Environment:
kubectl version
):1.8uname -a
):4.10.0-37What happened?
kubeadm init can be provided a config file as below:
kubeadm init --config kubeadm-policy-new.yaml
apiVersion: kubeadm.k8s.io/v1alpha1
kind: MasterConfiguration
schedulerExtraArgs:
policy-config-file: "/etc/kubernetes/sched_policy.json" <<< which tells kubeadm to start scheduler with policy.json file
This policy-config-file is not made available to the scheduler.
What you expected to happen?
The scheduler is succesfuly started with this configuration:
kube-scheduler --policy-config-file=/etc/kubernetes/sched_policy.json
however there is no /etc/kubernetes/sched_policy.json file mounted to the scheduler container. as a result the scheduler does not acknowledge the parameters in the policy file.
How to reproduce it (as minimally and precisely as possible)?
start kubeadm init with config file that contains parameter for scheduler args as shown below:
kubeadm init --config kubeadm-policy-new.yaml
apiVersion: kubeadm.k8s.io/v1alpha1
kind: MasterConfiguration
schedulerExtraArgs:
policy-config-file: "/etc/kubernetes/sched_policy.json" <<< which tells kubeadm to start scheduler with policy.json file
Anything else we need to know?
After creating a new container image using the base scheduler and copying the policy file, made the policy to be available for the scheduler. Below is the sample dockerfile used to create the new scheduler image:
'FROM gcr.io/google_containers/kube-scheduler-amd64:v1.8.2
COPY sched_policy.json /etc/kubernetes/sched_policy.json'
and use the local repository image option in the kubeadm config file as below:
'apiVersion: kubeadm.k8s.io/v1alpha1
kind: MasterConfiguration
schedulerExtraArgs:
policy-config-file: "/etc/kubernetes/sched_policy.json"
imageRepository: localhost:5000'
The text was updated successfully, but these errors were encountered: