upload Windows startup scripts to GCS for CI

pull/564/head
Michael Taufen 2019-02-25 13:53:11 -08:00
parent 1eb2acca99
commit 98edbf41bc
9 changed files with 75 additions and 0 deletions

View File

@ -38,6 +38,7 @@ gcs_upload(
":_binary-artifacts-and-hashes",
"//build/release-tars:release-tars-and-hashes",
"//cluster/gce/gci:gcs-release-artifacts-and-hashes",
"//cluster/gce/windows:gcs-release-artifacts-and-hashes",
],
tags = ["manual"],
# Use for_platforms to format the upload path based on the configured
@ -53,6 +54,7 @@ gcs_upload(
upload_paths = select(for_platforms(for_all = {
"//build/release-tars:release-tars-and-hashes": "",
"//cluster/gce/gci:gcs-release-artifacts-and-hashes": "extra/gce",
"//cluster/gce/windows:gcs-release-artifacts-and-hashes": "extra/gce/windows",
"//:_binary-artifacts-and-hashes": "bin/{OS}/{ARCH}",
})),
)

View File

@ -17,6 +17,7 @@ filegroup(
"//cluster/gce/addons:all-srcs",
"//cluster/gce/gci:all-srcs",
"//cluster/gce/manifests:all-srcs",
"//cluster/gce/windows:all-srcs",
],
tags = ["automanaged"],
)

35
cluster/gce/windows/BUILD Normal file
View File

@ -0,0 +1,35 @@
load("@io_k8s_repo_infra//defs:build.bzl", "release_filegroup")
# Having the Windows code from the GCE cluster deploy hosted with the release is
# useful for GKE. This list should match the list in k8s.io/release/lib/releaselib.sh.
# IMPORTANT PLEASE NOTE:
# Any time the file structure in the `windows` directory changes, `windows/BUILD`
# and `k8s.io/release/lib/releaselib.sh` must be manually updated with the changes.
# We HIGHLY recommend not changing the file structure, because consumers of
# Kubernetes releases depend on the release structure remaining stable.
release_filegroup(
name = "gcs-release-artifacts",
srcs = [
"common.psm1",
"configure.ps1",
"k8s-node-setup.psm1",
"testonly/install-ssh.psm1",
"testonly/user-profile.psm1",
],
visibility = ["//visibility:public"],
)
filegroup(
name = "package-srcs",
srcs = glob(["**"]),
tags = ["automanaged"],
visibility = ["//visibility:private"],
)
filegroup(
name = "all-srcs",
srcs = [":package-srcs"],
tags = ["automanaged"],
visibility = ["//visibility:public"],
)

View File

@ -1,5 +1,11 @@
# Starting a Windows Kubernetes cluster on GCE using kube-up
## IMPORTANT PLEASE NOTE!
Any time the file structure in the `windows` directory changes, `windows/BUILD`
and `k8s.io/release/lib/releaselib.sh` must be manually updated with the changes.
We HIGHLY recommend not changing the file structure, because consumers of
Kubernetes releases depend on the release structure remaining stable.
## Bring up the cluster
Prerequisites: a Google Cloud Platform project.
@ -185,3 +191,4 @@ These steps are based on
user@kubernetes-minion-windows-group-mk0p:C:\\etc\\kubernetes\\logs \
kubetest-logs/
```

View File

@ -18,6 +18,12 @@
and scripts for configuring Windows nodes.
#>
# IMPORTANT PLEASE NOTE:
# Any time the file structure in the `windows` directory changes, `windows/BUILD`
# and `k8s.io/release/lib/releaselib.sh` must be manually updated with the changes.
# We HIGHLY recommend not changing the file structure, because consumers of
# Kubernetes releases depend on the release structure remaining stable.
# Disable progress bar to increase download speed.
$ProgressPreference = 'SilentlyContinue'

View File

@ -17,6 +17,12 @@
Top-level script that runs on Windows nodes to join them to the K8s cluster.
#>
# IMPORTANT PLEASE NOTE:
# Any time the file structure in the `windows` directory changes, `windows/BUILD`
# and `k8s.io/release/lib/releaselib.sh` must be manually updated with the changes.
# We HIGHLY recommend not changing the file structure, because consumers of
# Kubernetes releases depend on the release structure remaining stable.
$ErrorActionPreference = 'Stop'
# Turn on tracing to debug

View File

@ -36,6 +36,12 @@
# Execute functions manually or run configure.ps1.
#>
# IMPORTANT PLEASE NOTE:
# Any time the file structure in the `windows` directory changes, `windows/BUILD`
# and `k8s.io/release/lib/releaselib.sh` must be manually updated with the changes.
# We HIGHLY recommend not changing the file structure, because consumers of
# Kubernetes releases depend on the release structure remaining stable.
# TODO: update scripts for these style guidelines:
# - Remove {} around variable references unless actually needed for clarity.
# - Always use single-quoted strings unless actually interpolating variables

View File

@ -22,6 +22,12 @@
clusters. DO NOT USE THIS MODULE FOR PRODUCTION.
#>
# IMPORTANT PLEASE NOTE:
# Any time the file structure in the `windows` directory changes, `windows/BUILD`
# and `k8s.io/release/lib/releaselib.sh` must be manually updated with the changes.
# We HIGHLY recommend not changing the file structure, because consumers of
# Kubernetes releases depend on the release structure remaining stable.
Import-Module -Force C:\common.psm1
$OPENSSH_ROOT = 'C:\Program Files\OpenSSH'

View File

@ -19,6 +19,12 @@
powershellposse.com
#>
# IMPORTANT PLEASE NOTE:
# Any time the file structure in the `windows` directory changes, `windows/BUILD`
# and `k8s.io/release/lib/releaselib.sh` must be manually updated with the changes.
# We HIGHLY recommend not changing the file structure, because consumers of
# Kubernetes releases depend on the release structure remaining stable.
#Function to create the new local user first
function New-LocalUser