Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
1091744a
Commit
1091744a
authored
Jan 06, 2015
by
Brendan Burns
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Address comments.
parent
ab429598
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
39 additions
and
15 deletions
+39
-15
get-kube.sh
cluster/get-kube.sh
+39
-15
No files found.
cluster/get-kube.sh
View file @
1091744a
...
@@ -34,11 +34,30 @@
...
@@ -34,11 +34,30 @@
# * export KUBERNETES_PROVIDER=vsphere; wget -q -O - https://get.k8s.io | sh
# * export KUBERNETES_PROVIDER=vsphere; wget -q -O - https://get.k8s.io | sh
# Rackspace
# Rackspace
# * export KUBERNETES_PROVIDER=rackspace; wget -q -O - https://get.k8s.io | sh
# * export KUBERNETES_PROVIDER=rackspace; wget -q -O - https://get.k8s.io | sh
#
# Set KUBERNETES_SKIP_DOWNLOAD to non-empty to skip downloading a release.
# Set KUBERNETES_SKIP_CONFIRM to skip the installation confirmation prompt.
set
-o
errexit
set
-o
errexit
set
-o
nounset
set
-o
nounset
set
-o
pipefail
set
-o
pipefail
function
create-cluster
{
echo
"Creating a kubernetes on
${
KUBERNETES_PROVIDER
:-
gce
}
..."
(
cd
kubernetes
./cluster/kube-up.sh
echo
"Kubernetes binaries at
${
PWD
}
/kubernetes/cluster/"
echo
"You may want to add this directory to your PATH in
\$
HOME/.profile"
echo
"Installation successful!"
)
}
if
[[
"
${
KUBERNETES_SKIP_DOWNLOAD
-
}
"
]]
;
then
create-cluster
exit
0
fi
release
=
v0.7.2
release
=
v0.7.2
release_url
=
https://storage.googleapis.com/kubernetes-release/release/
${
release
}
/kubernetes.tar.gz
release_url
=
https://storage.googleapis.com/kubernetes-release/release/
${
release
}
/kubernetes.tar.gz
...
@@ -48,7 +67,9 @@ if [[ "${uname}" == "Darwin" ]]; then
...
@@ -48,7 +67,9 @@ if [[ "${uname}" == "Darwin" ]]; then
elif
[[
"
${
uname
}
"
==
"Linux"
]]
;
then
elif
[[
"
${
uname
}
"
==
"Linux"
]]
;
then
platform
=
"linux"
platform
=
"linux"
else
else
echo
"Unknown, unsupported platform: (
${
uname
}
). Bailing out."
echo
"Unknown, unsupported platform: (
${
uname
}
)."
echo
"Supported platforms: Linux, Darwin."
echo
"Bailing out."
exit
2
exit
2
fi
fi
...
@@ -60,17 +81,29 @@ elif [[ "${machine}" == "i686" ]]; then
...
@@ -60,17 +81,29 @@ elif [[ "${machine}" == "i686" ]]; then
elif
[[
"
${
machine
}
"
==
"arm*"
]]
;
then
elif
[[
"
${
machine
}
"
==
"arm*"
]]
;
then
arch
=
"arm"
arch
=
"arm"
else
else
echo
"Unknown, unsupported architecture (
${
machine
}
). Bailing out."
echo
"Unknown, unsupported architecture (
${
machine
}
)."
echo
"Supported architectures x86_64, i686, arm*"
echo
"Bailing out."
exit
3
exit
3
fi
fi
file
=
kubernetes.tar.gz
file
=
kubernetes.tar.gz
echo
"Downloading kubernetes release
${
release
}
"
echo
"Downloading kubernetes release
${
release
}
to
${
PWD
}
/kubernetes.tar.gz"
if
[[
-n
"
${
KUBERNETES_SKIP_CONFIRM
-
}
"
]]
;
then
echo
"Is this ok? [Y]/n"
read
confirm
if
[[
"
$confirm
"
==
"n"
]]
;
then
echo
"Aborting."
exit
0
fi
fi
if
[[
$(
which wget
)
]]
;
then
if
[[
$(
which wget
)
]]
;
then
wget
-O
${
file
}
${
release_url
}
wget
-O
${
file
}
${
release_url
}
elif
[[
$(
which curl
)
]]
;
then
elif
[[
$(
which curl
)
]]
;
then
curl
-o
${
file
}
${
release_url
}
curl
-
L
-
o
${
file
}
${
release_url
}
else
else
echo
"Couldn't find curl or wget. Bailing out."
echo
"Couldn't find curl or wget. Bailing out."
exit
1
exit
1
...
@@ -80,14 +113,5 @@ echo "Unpacking kubernetes release ${release}"
...
@@ -80,14 +113,5 @@ echo "Unpacking kubernetes release ${release}"
tar
-xzf
${
file
}
tar
-xzf
${
file
}
rm
${
file
}
rm
${
file
}
echo
"Installing kubernetes..."
create-cluster
(
cd
kubernetes
./cluster/kube-up.sh
)
echo
"Kubernetes binaries at
${
PWD
}
/kubernetes/platforms/
${
platform
}
/
${
arch
}
/PATH"
echo
"You may want to add this directory to your PATH in
\$
HOME/.profile"
echo
"Installation successful!"
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment