Skip to content

Commit 728864e

Browse files
WIP fix tests
1 parent 7a8e1a9 commit 728864e

File tree

5 files changed

+8
-9
lines changed

5 files changed

+8
-9
lines changed

hack/lib/start.sh

+2-4
Original file line numberDiff line numberDiff line change
@@ -129,16 +129,14 @@ function os::start::internal::configure_master() {
129129
openshift_executable="$(os::start::internal::openshift_executable "${version}")"
130130

131131
os::log::debug "Creating master configuration for the OpenShift server"
132-
${openshift_executable} start \
132+
${openshift_executable} start master \
133133
--create-certs=false \
134134
--images="${USE_IMAGES}" \
135135
--master="${MASTER_ADDR}" \
136136
--dns="tcp://${API_HOST}:53" \
137-
--hostname="${KUBELET_HOST}" \
138-
--volume-dir="${VOLUME_DIR}" \
139137
--etcd-dir="${ETCD_DATA_DIR}" \
140138
--network-plugin="${NETWORK_PLUGIN:-}" \
141-
--write-config="${SERVER_CONFIG_DIR}" \
139+
--write-config="${SERVER_CONFIG_DIR}/master" \
142140
--listen="${API_SCHEME}://${API_BIND_HOST}:${API_PORT}" \
143141
--public-master="${API_SCHEME}://${PUBLIC_MASTER_HOST}:${API_PORT}"
144142

pkg/cmd/server/start/start_network.go

+3
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,9 @@ func (o NodeOptions) RunNode() error {
185185
// After this call returns without an error, config files will exist on disk. It also returns
186186
// a string for messages indicating which config file contains the config.
187187
func (o NodeOptions) resolveNodeConfig() (*configapi.NodeConfig, string, error) {
188+
if len(o.ConfigFile) == 0 {
189+
return nil, "", fmt.Errorf("you must specify a configuration file with --config")
190+
}
188191
glog.V(2).Infof("Reading node configuration from %s", o.ConfigFile)
189192
cfg, err := configapilatest.ReadAndResolveNodeConfig(o.ConfigFile)
190193
return cfg, o.ConfigFile, err

pkg/oc/clusterup/coreinstall/kubelet/flags.go

+1-3
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,6 @@ func (opt KubeletStartFlags) MakeKubeletFlags(dockerClient dockerhelper.Interfac
3636
}
3737

3838
createFlagsCmd := []string{
39-
"start", "node",
40-
"--write-flags",
4139
"--config=/var/lib/origin/openshift.local.config/node/node-config.yaml",
4240
}
4341

@@ -46,7 +44,7 @@ func (opt KubeletStartFlags) MakeKubeletFlags(dockerClient dockerhelper.Interfac
4644
Bind(binds...).
4745
Env(env...).
4846
SaveContainerLogs(componentName, path.Join(basedir, "logs")).
49-
Entrypoint("openshift").
47+
Entrypoint("openshift-node-config").
5048
Command(createFlagsCmd...).Output()
5149
if err != nil {
5250
return "", errors.NewError("could not run %q: %v", componentName, err).WithCause(err)

test/cmd/admin.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ os::test::junit::declare_suite_start "cmd/admin"
3232

3333
os::test::junit::declare_suite_start "cmd/admin/start"
3434
# Check failure modes of various system commands
35-
os::cmd::expect_failure_and_text 'openshift start network' 'kubeconfig must be set'
35+
os::cmd::expect_failure_and_text 'openshift start network' 'you must specify a configuration file with --config'
3636
os::cmd::expect_failure_and_text 'openshift start network --config=${NODECONFIG} --enable=kubelet' 'the following components are not recognized: kubelet'
3737
os::cmd::expect_failure_and_text 'openshift start network --config=${NODECONFIG} --enable=kubelet,other' 'the following components are not recognized: kubelet, other'
3838
os::cmd::expect_failure_and_text 'openshift start network --config=${NODECONFIG} --disable=other' 'the following components are not recognized: other'

test/cmd/help.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ os::cmd::expect_success_and_text 'oc login --help' 'insecure-skip-tls-verify'
4141

4242
# help for given command with --help flag must be consistent
4343
os::cmd::expect_success_and_text 'oc get --help' 'Display one or many resources'
44-
os::cmd::expect_success_and_text 'openshift start --help' 'Launch OpenShift components'
44+
os::cmd::expect_success_and_text 'openshift start --help' 'Start components of OpenShift'
4545
os::cmd::expect_success_and_text 'openshift start master --help' 'Start a master'
4646
os::cmd::expect_success_and_text 'openshift start network --help' 'Start networking'
4747
os::cmd::expect_success_and_text 'oc project --help' 'Switch to another project'

0 commit comments

Comments
 (0)