Hello community, here is the log from the commit of package kubernetes for openSUSE:Factory checked in at 2017-08-12 20:25:26 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/kubernetes (Old) and /work/SRC/openSUSE:Factory/.kubernetes.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "kubernetes" Sat Aug 12 20:25:26 2017 rev:4 rq:513801 version:1.7.0 Changes: -------- --- /work/SRC/openSUSE:Factory/kubernetes/kubernetes.changes 2017-06-20 09:40:36.914208003 +0200 +++ /work/SRC/openSUSE:Factory/.kubernetes.new/kubernetes.changes 2017-08-12 20:25:28.486555554 +0200 @@ -1,0 +2,19 @@ +Thu Jul 13 08:46:41 UTC 2017 - [email protected] + +- Update to version 1.7.0: + * Kubernetes 1.7 is a milestone release that adds security, stateful application, + and extensibility features motivated by widespread production use of Kubernetes. + * Security enhancements in this release include encrypted secrets (alpha), + network policy for pod-to-pod communication, the node authorizer to limit Kubelet + access to API resources, and Kubelet client / server TLS certificate rotation (alpha). + * Major features for stateful applications include automated updates to StatefulSets, + enhanced updates for DaemonSets, a burst mode for faster StatefulSets scaling, + and (alpha) support for local storage. + * Extensibility features include API aggregation (beta), CustomResourceDefinitions (beta) + in favor of ThirdPartyResources, support for extensible admission controllers (alpha), + pluggable cloud providers (alpha), and container runtime interface (CRI) enhancements. +- Remove the following patches: + * add_pr_template.patch: got merged upstream + * fix-support-for-ppc64le.patch: no longer needed, we are not using gccgo anymore + +------------------------------------------------------------------- @@ -8 +27 @@ -Mon May 15 16:54:22 UTC 2017 - [email protected] +Wed Jun 7 10:35:21 UTC 2017 - [email protected] @@ -10,4 +29,5 @@ -- Adding a /etc/kubernetes/kubelet-initial EnvironmentFile that is expected - to set the KUBELET_INITIAL_ARGS variable so that a set of arguments that - only impact kubelet on the first run can be supplied. This removes the - need to restart kubelet when you change the node labels, for example. +- Change default kubernetes log level: use warning as base level of logging, + not debug. +- Change default kubelet configuration: do not tell kubelet to look for + the API server on localhost. 90% of the times this process is located + somewhere else. This also helps to fix/mitigate bsc#1042387 @@ -16 +36,14 @@ -Mon May 15 16:51:39 UTC 2017 - [email protected] +Mon Jun 5 09:50:11 UTC 2017 - [email protected] + +- Add kubelet-support-btrfs-fixes-bsc-1042383.patch needed to fix bsc#1042383 +- Removed commented line referring to a patch file no longer shipped + +------------------------------------------------------------------- +Fri May 19 11:14:34 UTC 2017 - [email protected] + +- Downgrade to version 1.5.3 because we just hit some new issues + (bsc#1039663) with k8s 1.6 and we don't have time to properly fix + and test 1.6, to make sure there are no new bugs, before the release. + +------------------------------------------------------------------- +Mon May 15 16:54:22 UTC 2017 - [email protected] Old: ---- add_pr_template.patch fix-support-for-ppc64le.patch kubernetes-1.6.1.tar.xz New: ---- kubelet-support-btrfs-fixes-bsc-1042383.patch kubernetes-1.7.0.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ kubernetes.spec ++++++ --- /var/tmp/diff_new_pack.6Pj79f/_old 2017-08-12 20:25:29.466418242 +0200 +++ /var/tmp/diff_new_pack.6Pj79f/_new 2017-08-12 20:25:29.474417122 +0200 @@ -18,7 +18,7 @@ %{!?tmpfiles_create:%global tmpfiles_create systemd-tmpfiles --create} Name: kubernetes -Version: 1.6.1 +Version: 1.7.0 Release: 0 Summary: Container Scheduling and Management License: Apache-2.0 @@ -43,19 +43,21 @@ Source27: kubernetes-rpmlintrc # Patches so it also builds in ppc64le and arm64. Patch1: git-upstream.patch -Patch3: add_pr_template.patch Patch4: make-e2e_node-run-over-distro-bins.patch Patch6: build-with-debug-info.patch -Patch7: fix-support-for-ppc64le.patch +# Fixes bsc#1042383 +Patch8: kubelet-support-btrfs-fixes-bsc-1042383.patch BuildRequires: bash-completion BuildRequires: git # Building k8s pre-1.7 with go >= 1.8 does NOT work: https://github.com/kubernetes/kubernetes/issues/45935 +BuildRequires: fdupes +BuildRequires: go >= 1.8.3 BuildRequires: go-go-md2man BuildRequires: golang-packaging BuildRequires: rsync BuildRequires: systemd-rpm-macros -BuildRequires: golang(API) = 1.7 +BuildRequires: golang(API) = 1.8 BuildRequires: golang(github.com/jteeuwen/go-bindata) ExcludeArch: %ix86 %{go_nostrip} @@ -175,11 +177,9 @@ %prep %setup -q %patch1 -p1 -#%patch2 -p1 -%patch3 -p1 %patch4 -p1 %patch6 -p1 -%patch7 -p1 +%patch8 -p1 %{goprep} github.com/kubernetes/kubernetes %build ++++++ _service ++++++ --- /var/tmp/diff_new_pack.6Pj79f/_old 2017-08-12 20:25:29.566404231 +0200 +++ /var/tmp/diff_new_pack.6Pj79f/_new 2017-08-12 20:25:29.574403110 +0200 @@ -4,8 +4,8 @@ <param name="scm">git</param> <param name="filename">kubernetes</param> <param name="exclude">.git</param> - <param name="versionformat">1.6.1</param> - <param name="revision">v1.6.1</param> + <param name="versionformat">1.7.0</param> + <param name="revision">v1.7.0</param> <param name="changesgenerate">enable</param> </service> <service name="recompress" mode="disabled"> ++++++ build-with-debug-info.patch ++++++ --- /var/tmp/diff_new_pack.6Pj79f/_old 2017-08-12 20:25:29.610398066 +0200 +++ /var/tmp/diff_new_pack.6Pj79f/_new 2017-08-12 20:25:29.610398066 +0200 @@ -1,9 +1,9 @@ -diff --git a/hack/lib/golang.sh b/hack/lib/golang.sh -index c1259a4..9bf8243 100755 ---- a/hack/lib/golang.sh -+++ b/hack/lib/golang.sh -@@ -508,7 +508,7 @@ kube::golang::build_binaries_for_platform() { - CGO_ENABLED=0 "${GO}" build -o "${outfile}" \ +Index: kubernetes-1.7.0/hack/lib/golang.sh +=================================================================== +--- kubernetes-1.7.0.orig/hack/lib/golang.sh ++++ kubernetes-1.7.0/hack/lib/golang.sh +@@ -505,7 +505,7 @@ kube::golang::build_binaries_for_platfor + CGO_ENABLED=0 go build -o "${outfile}" \ "${goflags[@]:+${goflags[@]}}" \ -gcflags "${gogcflags}" \ - -ldflags "${goldflags}" \ @@ -11,8 +11,8 @@ "${binary}" kube::log::progress "*" done -@@ -517,7 +517,7 @@ kube::golang::build_binaries_for_platform() { - "${GO}" build -o "${outfile}" \ +@@ -514,7 +514,7 @@ kube::golang::build_binaries_for_platfor + go build -o "${outfile}" \ "${goflags[@]:+${goflags[@]}}" \ -gcflags "${gogcflags}" \ - -ldflags "${goldflags}" \ ++++++ config ++++++ --- /var/tmp/diff_new_pack.6Pj79f/_old 2017-08-12 20:25:29.670389660 +0200 +++ /var/tmp/diff_new_pack.6Pj79f/_new 2017-08-12 20:25:29.682387978 +0200 @@ -12,7 +12,7 @@ KUBE_LOGTOSTDERR="--logtostderr=true" # journal message level, 0 is debug -KUBE_LOG_LEVEL="--v=0" +KUBE_LOG_LEVEL="--v=2" # Should this cluster be allowed to run privileged docker containers KUBE_ALLOW_PRIV="--allow-privileged=false" ++++++ kubelet ++++++ --- /var/tmp/diff_new_pack.6Pj79f/_old 2017-08-12 20:25:29.870361636 +0200 +++ /var/tmp/diff_new_pack.6Pj79f/_new 2017-08-12 20:25:29.870361636 +0200 @@ -10,8 +10,5 @@ # You may leave this blank to use the actual hostname KUBELET_HOSTNAME="--hostname-override=127.0.0.1" -# location of the api-server -KUBELET_API_SERVER="--api-servers=http://127.0.0.1:8080" - # Add your own! KUBELET_ARGS="--pod-manifest-path=/etc/kubernetes/manifests" ++++++ kubelet-support-btrfs-fixes-bsc-1042383.patch ++++++ >From 434c8c0aa319e3b3da8d64d833fb03dda906d050 Mon Sep 17 00:00:00 2001 From: Flavio Castelli <[email protected]> Date: Tue, 6 Jun 2017 16:48:57 +0200 Subject: [PATCH] kubelet: fix disk space check on btrfs (issue 47046) This commit fixes the warning messages reported by kubelet when checking for the disk space on a btrfs `/` which has `/var/lib/kubelet` inside of a btrfs sub-volume. This fix follows the same principle adopted to fix issue #38337 with commit dc8b6cc. This commit fixes issue 47046. Signed-off-by: Flavio Castelli <[email protected]> --- vendor/github.com/google/cadvisor/fs/fs.go | 55 ++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) Index: kubernetes-1.7.0/vendor/github.com/google/cadvisor/fs/fs.go =================================================================== --- kubernetes-1.7.0.orig/vendor/github.com/google/cadvisor/fs/fs.go +++ kubernetes-1.7.0/vendor/github.com/google/cadvisor/fs/fs.go @@ -79,6 +79,8 @@ type RealFsInfo struct { // Map from label to block device path. // Labels are intent-specific tags that are auto-detected. labels map[string]string + // Map from mountpoint to mount information. + mounts map[string]*mount.Info // devicemapper client dmsetup devicemapper.DmsetupClient } @@ -106,9 +108,14 @@ func NewFsInfo(context Context) (FsInfo, fsInfo := &RealFsInfo{ partitions: processMounts(mounts, excluded), labels: make(map[string]string, 0), + mounts: make(map[string]*mount.Info, 0), dmsetup: devicemapper.NewDmsetupClient(), } + for _, mount := range mounts { + fsInfo.mounts[mount.Mountpoint] = mount + } + fsInfo.addRktImagesLabel(context, mounts) // need to call this before the log line below printing out the partitions, as this function may // add a "partition" for devicemapper to fsInfo.partitions @@ -152,25 +159,10 @@ func processMounts(mounts []*mount.Info, // btrfs fix: following workaround fixes wrong btrfs Major and Minor Ids reported in /proc/self/mountinfo. // instead of using values from /proc/self/mountinfo we use stat to get Ids from btrfs mount point if mount.Fstype == "btrfs" && mount.Major == 0 && strings.HasPrefix(mount.Source, "/dev/") { - - buf := new(syscall.Stat_t) - err := syscall.Stat(mount.Source, buf) - if err != nil { - glog.Warningf("stat failed on %s with error: %s", mount.Source, err) - } else { - glog.Infof("btrfs mount %#v", mount) - if buf.Mode&syscall.S_IFMT == syscall.S_IFBLK { - err := syscall.Stat(mount.Mountpoint, buf) - if err != nil { - glog.Warningf("stat failed on %s with error: %s", mount.Mountpoint, err) - } else { - glog.Infof("btrfs dev major:minor %d:%d\n", int(major(buf.Dev)), int(minor(buf.Dev))) - glog.Infof("btrfs rdev major:minor %d:%d\n", int(major(buf.Rdev)), int(minor(buf.Rdev))) - - mount.Major = int(major(buf.Dev)) - mount.Minor = int(minor(buf.Dev)) - } - } + major, minor, ok := getBtrfsMajorMinorIds(mount) + if ok { + mount.Major = major + mount.Minor = minor } } @@ -444,6 +436,7 @@ func (self *RealFsInfo) GetDirFsDevice(d if err != nil { return nil, fmt.Errorf("stat failed on %s with error: %s", dir, err) } + major := major(buf.Dev) minor := minor(buf.Dev) for device, partition := range self.partitions { @@ -451,6 +444,14 @@ func (self *RealFsInfo) GetDirFsDevice(d return &DeviceInfo{device, major, minor}, nil } } + + mount, ok := self.mounts[dir] + if ok && mount.Fstype == "btrfs" && mount.Major == 0 && strings.HasPrefix(mount.Source, "/dev/") { + major, minor, ok := getBtrfsMajorMinorIds(mount) + if ok { + return &DeviceInfo{mount.Source, uint(major), uint(minor)}, nil + } + } return nil, fmt.Errorf("could not find device with major: %d, minor: %d in cached partitions map", major, minor) } @@ -637,6 +638,35 @@ func getZfstats(poolName string) (uint64 return total, dataset.Avail, dataset.Avail, nil } +// Get major and minor Ids for a mount point using btrfs as filesystem. +// The boolean is set to true when both the values are successfully retrieved. +func getBtrfsMajorMinorIds(mount *mount.Info) (int, int, bool) { + // btrfs fix: following workaround fixes wrong btrfs Major and Minor Ids reported in /proc/self/mountinfo. + // instead of using values from /proc/self/mountinfo we use stat to get Ids from btrfs mount point + + buf := new(syscall.Stat_t) + err := syscall.Stat(mount.Source, buf) + if err != nil { + glog.Warningf("stat failed on %s with error: %s", mount.Source, err) + return 0, 0, false + } + + glog.Infof("btrfs mount %#v", mount) + if buf.Mode&syscall.S_IFMT == syscall.S_IFBLK { + err := syscall.Stat(mount.Mountpoint, buf) + if err != nil { + glog.Warningf("stat failed on %s with error: %s", mount.Mountpoint, err) + return 0, 0, false + } + + glog.Infof("btrfs dev major:minor %d:%d\n", int(major(buf.Dev)), int(minor(buf.Dev))) + glog.Infof("btrfs rdev major:minor %d:%d\n", int(major(buf.Rdev)), int(minor(buf.Rdev))) + + return int(major(buf.Dev)), int(minor(buf.Dev)), true + } + return 0, 0, false +} + // Simple io.Writer implementation that counts how many bytes were written. type byteCounter struct{ bytesWritten uint64 } ++++++ kubernetes-1.6.1.tar.xz -> kubernetes-1.7.0.tar.xz ++++++ /work/SRC/openSUSE:Factory/kubernetes/kubernetes-1.6.1.tar.xz /work/SRC/openSUSE:Factory/.kubernetes.new/kubernetes-1.7.0.tar.xz differ: char 25, line 1 ++++++ make-e2e_node-run-over-distro-bins.patch ++++++ --- /var/tmp/diff_new_pack.6Pj79f/_old 2017-08-12 20:25:30.002343141 +0200 +++ /var/tmp/diff_new_pack.6Pj79f/_new 2017-08-12 20:25:30.002343141 +0200 @@ -1,8 +1,8 @@ -diff --git a/hack/lib/init.sh b/hack/lib/init.sh -index a07f6f2..fc9f0d8 100644 ---- a/hack/lib/init.sh -+++ b/hack/lib/init.sh -@@ -46,7 +46,7 @@ source "${KUBE_ROOT}/hack/lib/version.sh" +Index: kubernetes-1.7.0/hack/lib/init.sh +=================================================================== +--- kubernetes-1.7.0.orig/hack/lib/init.sh ++++ kubernetes-1.7.0/hack/lib/init.sh +@@ -45,7 +45,7 @@ source "${KUBE_ROOT}/hack/lib/version.sh source "${KUBE_ROOT}/hack/lib/golang.sh" source "${KUBE_ROOT}/hack/lib/etcd.sh" @@ -11,22 +11,22 @@ # list of all available group versions. This should be used when generated code # or when starting an API server that you want to have everything. -diff --git a/hack/make-rules/test-e2e-node.sh b/hack/make-rules/test-e2e-node.sh -index 20cea09..4190c19 100755 ---- a/hack/make-rules/test-e2e-node.sh -+++ b/hack/make-rules/test-e2e-node.sh -@@ -155,6 +155,6 @@ else - # Provided for backwards compatibility - go run test/e2e_node/runner/local/run_local.go --ginkgo-flags="$ginkgoflags" \ - --test-flags="--container-runtime=${runtime} --alsologtostderr --v 4 --report-dir=${artifacts} --node-name $(hostname) \ +Index: kubernetes-1.7.0/hack/make-rules/test-e2e-node.sh +=================================================================== +--- kubernetes-1.7.0.orig/hack/make-rules/test-e2e-node.sh ++++ kubernetes-1.7.0/hack/make-rules/test-e2e-node.sh +@@ -168,6 +168,6 @@ else + --container-runtime-endpoint=${container_runtime_endpoint} \ + --image-service-endpoint=${image_service_endpoint} \ + --alsologtostderr --v 4 --report-dir=${artifacts} --node-name $(hostname) \ - $test_args" --build-dependencies=true 2>&1 | tee -i "${artifacts}/build-log.txt" + $test_args --k8s-bin-dir /usr/bin" --build-dependencies=true 2>&1 | tee -i "${artifacts}/build-log.txt" exit $? fi -diff --git a/test/e2e_node/builder/build.go b/test/e2e_node/builder/build.go -index f22232a..ef60a41 100644 ---- a/test/e2e_node/builder/build.go -+++ b/test/e2e_node/builder/build.go +Index: kubernetes-1.7.0/test/e2e_node/builder/build.go +=================================================================== +--- kubernetes-1.7.0.orig/test/e2e_node/builder/build.go ++++ kubernetes-1.7.0/test/e2e_node/builder/build.go @@ -31,7 +31,7 @@ import ( var k8sBinDir = flag.String("k8s-bin-dir", "", "Directory containing k8s kubelet binaries.") @@ -47,11 +47,11 @@ func getK8sBin(bin string) (string, error) { // Use commandline specified path if *k8sBinDir != "" { -diff --git a/test/e2e_node/services/services.go b/test/e2e_node/services/services.go -index c206a85..7019af8 100644 ---- a/test/e2e_node/services/services.go -+++ b/test/e2e_node/services/services.go -@@ -141,6 +141,11 @@ func (e *E2EServices) startInternalServices() (*server, error) { +Index: kubernetes-1.7.0/test/e2e_node/services/services.go +=================================================================== +--- kubernetes-1.7.0.orig/test/e2e_node/services/services.go ++++ kubernetes-1.7.0/test/e2e_node/services/services.go +@@ -141,6 +141,11 @@ func (e *E2EServices) startInternalServi } // Pass all flags into the child process, so that it will see the same flag set. startCmd := exec.Command(testBin, append([]string{"--run-services-mode"}, os.Args[1:]...)...)
