@@ -75,6 +75,18 @@ readonly OPENSHIFT_BINARY_SYMLINKS=(
75
75
)
76
76
readonly OPENSHIFT_BINARY_COPY=(
77
77
oadm
78
+ kubelet
79
+ kube-proxy
80
+ kube-apiserver
81
+ kube-controller-manager
82
+ kube-scheduler
83
+ )
84
+ readonly OC_BINARY_COPY=(
85
+ kubectl
86
+ )
87
+ readonly OS_BINARY_RELEASE_WINDOWS=(
88
+ oc.exe
89
+ kubectl.exe
78
90
)
79
91
80
92
# os::build::binaries_from_targets take a list of build targets and return the
@@ -316,16 +328,29 @@ os::build::place_bins() {
316
328
for linkname in " ${OPENSHIFT_BINARY_COPY[@]} " ; do
317
329
local src=" ${release_binpath} /openshift${suffix} "
318
330
if [[ -f " ${src} " ]]; then
319
- cp " ${release_binpath} /openshift${suffix} " " ${release_binpath} /${linkname}${suffix} "
331
+ ln " ${release_binpath} /openshift${suffix} " " ${release_binpath} /${linkname}${suffix} "
332
+ fi
333
+ done
334
+ for linkname in " ${OC_BINARY_COPY[@]} " ; do
335
+ local src=" ${release_binpath} /oc${suffix} "
336
+ if [[ -f " ${src} " ]]; then
337
+ ln " ${release_binpath} /oc${suffix} " " ${release_binpath} /${linkname}${suffix} "
320
338
fi
321
339
done
322
340
323
341
# Create the release archive.
324
342
local platform_segment=" ${platform// \/ / -} "
325
- local archive_name=" ${OS_RELEASE_ARCHIVE} -${OS_GIT_VERSION} -${OS_GIT_COMMIT} -${platform_segment} .tar.gz"
326
-
327
- echo " ++ Creating ${archive_name} "
328
- tar -czf " ${OS_LOCAL_RELEASEPATH} /${archive_name} " -C " ${release_binpath} " .
343
+ if [[ $platform == " windows/amd64" ]]; then
344
+ local archive_name=" ${OS_RELEASE_ARCHIVE} -${OS_GIT_VERSION} -${OS_GIT_COMMIT} -${platform_segment} .zip"
345
+ echo " ++ Creating ${archive_name} "
346
+ for file in " ${OS_BINARY_RELEASE_WINDOWS[@]} " ; do
347
+ zip " ${OS_LOCAL_RELEASEPATH} /${archive_name} " -qj " ${release_binpath} /${file} "
348
+ done
349
+ else
350
+ local archive_name=" ${OS_RELEASE_ARCHIVE} -${OS_GIT_VERSION} -${OS_GIT_COMMIT} -${platform_segment} .tar.gz"
351
+ echo " ++ Creating ${archive_name} "
352
+ tar -czf " ${OS_LOCAL_RELEASEPATH} /${archive_name} " -C " ${release_binpath} " .
353
+ fi
329
354
rm -rf " ${release_binpath} "
330
355
done
331
356
)
0 commit comments