jsenon / api-cni-cleanup Goto Github PK
View Code? Open in Web Editor NEWKubernetes CNI cleanner
License: Apache License 2.0
Kubernetes CNI cleanner
License: Apache License 2.0
Getting following error durng deployement.
1s 3s 10 api-cni-cleanup.160e1f58acb265d1 DaemonSet Warning FailedCreate daemonset-controller Error creating: pods "api-cni-cleanup-" is forbidden: unable to validate against any security context constraint: [spec.volumes[0]: Invalid value: "hostPath": hostPath volumes are not allowed to be used spec.volumes[1]: Invalid value: "hostPath": hostPath volumes are not allowed to be used]
Hello @jsenon,
Thank you for the workaround.
I tried to implement it but it didn't work out. Below is the information:
K8s version: 1.11
Set-up by Kops on AWS EC2 nodes
OS: Ubuntu:16.04
Issue:
I ran it as a daemonset and commented out CronJob part (as suggested by you in your Readme) but I assume daemonset should run in kube-system namespace which was missing from the deployment.yaml file. Without mentioning it was failing. I added it and then deployed it as (DaemonSet, Service, ClusterRole, ClusterRoleBinding, ServiceAccount) and all are in kube-system namespace.
It was running fine but was not deleting the stale IP files.
Upon seeing the logs of the pod it was running as expected and when I hit the http://::/cleanup it didn't delete the CNI files. Don't know why?
Can you shed some light on this?
Screenshots:
API-CNI Pods:
Upon seeing the directory on the node (ls /var/lib/cni/networks/cbr0 | wc -l) I am getting an output 254. Hope this info helps you to understand the problem-statement.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.