Merge pull request #50211 from NuxiNL/util-freebsd

Automatic merge from submit-queue (batch tested with PRs 49869, 47987, 50211, 50804, 50583)

Make socket address parsing work on FreeBSD.

**What this PR does / why we need it**:

I am currently in the process of porting Kubernetes to work on FreeBSD. What is interesting is that I am not interested in using Kubernetes to run Docker containers in this case. I happen to be the author of CloudABI, a sandboxing framework that is available on FreeBSD (and other systems). I want to have a cluster management tool for scheduling these sandboxed processes.

Anyway, right now `kubelet` crashes on startup when passing in CRI command line flags, for the reason that it's not able to parse `unix:...` socket addresses. This change fixes this by making the respective Linux-only source file work on FreeBSD as well.
This commit is contained in:
Kubernetes Submit Queue 2017-08-17 01:32:21 -07:00 committed by GitHub
commit c8cfc5f723
3 changed files with 3 additions and 3 deletions

View File

@ -21,7 +21,7 @@ go_library(
"util_unsupported.go", "util_unsupported.go",
] + select({ ] + select({
"@io_bazel_rules_go//go/platform:linux_amd64": [ "@io_bazel_rules_go//go/platform:linux_amd64": [
"util_linux.go", "util_unix.go",
], ],
"@io_bazel_rules_go//go/platform:windows_amd64": [ "@io_bazel_rules_go//go/platform:windows_amd64": [
"util_windows.go", "util_windows.go",

View File

@ -1,4 +1,4 @@
// +build linux // +build freebsd linux
/* /*
Copyright 2017 The Kubernetes Authors. Copyright 2017 The Kubernetes Authors.

View File

@ -1,4 +1,4 @@
// +build !linux,!windows // +build !freebsd,!linux,!windows
/* /*
Copyright 2017 The Kubernetes Authors. Copyright 2017 The Kubernetes Authors.