Merge pull request #7048 from afbjorklund/reportcard-1.8.2

Improve reportcard for the v1.8.2 release
pull/7055/head
Medya Ghazizadeh 2020-03-14 19:22:24 -07:00 committed by GitHub
commit bf1b6d799c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 16 additions and 7 deletions

View File

@ -847,6 +847,13 @@ func generateCfgFromFlags(cmd *cobra.Command, k8sVersion string, drvName string)
kubeNodeName = "m01"
}
return createNode(cmd, k8sVersion, kubeNodeName, drvName,
repository, selectedEnableDefaultCNI, selectedNetworkPlugin)
}
func createNode(cmd *cobra.Command, k8sVersion, kubeNodeName, drvName, repository string,
selectedEnableDefaultCNI bool, selectedNetworkPlugin string) (config.ClusterConfig, config.Node, error) {
sysLimit, containerLimit, err := memoryLimits(drvName)
if err != nil {
glog.Warningf("Unable to query memory limits: %v", err)

View File

@ -37,10 +37,12 @@ import (
// KubernetesContainerPrefix is the prefix of each kubernetes container
const KubernetesContainerPrefix = "k8s_"
// ErrISOFeature is the error returned when disk image is missing features
type ErrISOFeature struct {
missing string
}
// NewErrISOFeature creates a new ErrISOFeature
func NewErrISOFeature(missing string) *ErrISOFeature {
return &ErrISOFeature{
missing: missing,

View File

@ -25,11 +25,11 @@ import (
func TestMergeReferenceStores(t *testing.T) {
initial := ReferenceStore{
Repositories: map[string]repository{
"image1": repository{
"image1": {
"r1": "d1",
"r2": "d2",
},
"image2": repository{
"image2": {
"r1": "d1",
"r2": "d2",
},
@ -38,11 +38,11 @@ func TestMergeReferenceStores(t *testing.T) {
afterPreload := ReferenceStore{
Repositories: map[string]repository{
"image1": repository{
"image1": {
"r1": "updated",
"r2": "updated",
},
"image3": repository{
"image3": {
"r3": "d3",
},
},
@ -50,15 +50,15 @@ func TestMergeReferenceStores(t *testing.T) {
expected := ReferenceStore{
Repositories: map[string]repository{
"image1": repository{
"image1": {
"r1": "updated",
"r2": "updated",
},
"image2": repository{
"image2": {
"r1": "d1",
"r2": "d2",
},
"image3": repository{
"image3": {
"r3": "d3",
},
},