Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
K
k8s-install
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Wen Wei Li
k8s-install
Commits
ee61d2cd
Commit
ee61d2cd
authored
Apr 09, 2024
by
Wen Wei Li
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update k8s-install
parent
b35572c2
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
.gitignore
.gitignore
+1
-0
k8s-install.sh
k8s-install.sh
+6
-7
No files found.
.gitignore
0 → 100644
View file @
ee61d2cd
hosts
k8s-install.sh
View file @
ee61d2cd
...
...
@@ -86,8 +86,8 @@ eval "curl -L https://download.opensuse.org/repositories/devel:/kubic:/libcontai
# install cri-o
eval
"apt-get update"
eval
"apt-get install cri-o cri-o-runc"
eval
"apt-get update
--force-yes
"
eval
"apt-get install cri-o cri-o-runc
-y
"
eval
"systemctl daemon-reload"
eval
"systemctl enable crio"
eval
"systemctl start crio"
...
...
@@ -98,8 +98,7 @@ echo "Complete install CRI-O"
install_k8s
(){
# install k8s
export
KUBE_VERSION
=
v1.28
# 執行下面指令
eval
"apt-get update"
eval
"apt-get update -y"
# apt-transport-https may be a dummy package; if so, you can skip that package
eval
"apt-get install -y apt-transport-https ca-certificates curl gpg"
...
...
@@ -107,7 +106,7 @@ eval "curl -fsSL https://pkgs.k8s.io/core:/stable:/$KUBE_VERSION/deb/Release.key
# This overwrites any existing configuration in /etc/apt/sources.list.d/kubernetes.list
echo
"deb [signed-by=/etc/apt/keyrings/kubernetes-apt-keyring.gpg] https://pkgs.k8s.io/core:/stable:/
$KUBE_VERSION
/deb/ /"
|
sudo tee
/etc/apt/sources.list.d/kubernetes.list
eval
"apt-get update"
eval
"apt-get update
-y
"
eval
"apt-get install -y kubelet kubeadm kubectl"
eval
"apt-mark hold kubelet kubeadm kubectl"
...
...
@@ -239,7 +238,7 @@ main(){
#update_system
echo
"Installing"
copy_host_file
$1
if
[[
$2
==
"cp"
]]
;
then
if
[[
$2
==
"cp"
]]
;
then
prerequisite
install_cri
install_k8s
...
...
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