-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5adf576
commit f0edc77
Showing
26 changed files
with
6,279 additions
and
373 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,8 @@ | ||
FROM scratch | ||
COPY rootfs/* . | ||
COPY ${ARCH}/* . | ||
COPY rootfs . | ||
COPY amd64 . | ||
COPY imageList manifests | ||
COPY tigera-operator.yaml applications/tigera-operator.yaml | ||
COPY custom-resources.yaml applications/custom-resources.yaml | ||
APP calico local://calico.sh | ||
LAUNCH ["calico"] |
Binary file not shown.
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/bin/bash | ||
|
||
kubectl apply -f applications/tigera-operator.yaml | ||
kubectl apply -f applications/custom-resources.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
#!/bin/bash | ||
# shellcheck disable=SC1091 | ||
# Copyright © 2021 Alibaba Group Holding Ltd. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
set -x | ||
set -e | ||
|
||
rootfs=$(dirname "$(pwd)") | ||
image_dir="$rootfs/images" | ||
lib_dir="${rootfs}/lib" | ||
dump_config_dir="$rootfs/etc/dump-config.toml" | ||
|
||
command_exists() { | ||
command -v "$@" >/dev/null 2>&1 | ||
} | ||
|
||
server_load_images() { | ||
for image in "$image_dir"/*; do | ||
if [ -f "${image}" ]; then | ||
${1} load -i "${image}" | ||
fi | ||
done | ||
} | ||
|
||
##cri is containerd | ||
if ! command_exists containerd; then | ||
tar zxvf ../cri/cri-*.tar.gz -C / | ||
cd "$lib_dir" && source install_libseccomp.sh | ||
fi | ||
systemctl daemon-reload | ||
systemctl enable containerd.service | ||
systemctl restart containerd.service | ||
|
||
sed -i "s/sea.hub/${2:-sea.hub}/g" "$dump_config_dir" | ||
sed -i "s/5000/${3:-5000}/g" "$dump_config_dir" | ||
mkdir -p /etc/containerd | ||
containerd --config "$dump_config_dir" config dump >/etc/containerd/config.toml | ||
systemctl restart containerd.service | ||
load_image_server="nerdctl" | ||
|
||
server_load_images "${load_image_server}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# This section includes base Calico installation configuration. | ||
# For more information, see: https://projectcalico.docs.tigera.io/v3.22/reference/installation/api#operator.tigera.io/v1.Installation | ||
apiVersion: operator.tigera.io/v1 | ||
kind: Installation | ||
metadata: | ||
name: default | ||
spec: | ||
# Configures Calico networking. | ||
registry: sea.hub:5000 | ||
calicoNetwork: | ||
# Note: The ipPools section cannot be modified post-install. | ||
ipPools: | ||
- blockSize: 26 | ||
cidr: 100.64.0.0/10 | ||
encapsulation: VXLANCrossSubnet | ||
natOutgoing: Enabled | ||
nodeSelector: all() | ||
|
||
--- | ||
|
||
# This section configures the Calico API server. | ||
# For more information, see: https://projectcalico.docs.tigera.io/v3.22/reference/installation/api#operator.tigera.io/v1.APIServer | ||
apiVersion: operator.tigera.io/v1 | ||
kind: APIServer | ||
metadata: | ||
name: default | ||
spec: {} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,19 @@ | ||
{ | ||
"experimental": true, | ||
"oom-score-adjust": -1000, | ||
"max-concurrent-downloads": 20, | ||
"log-driver": "json-file", | ||
"log-level": "warn", | ||
"log-opts": { | ||
"max-size": "10m", | ||
"max-file": "3" | ||
}, | ||
"mirror-registries": [ | ||
{ | ||
"domain": "*", | ||
"mirrors": [ | ||
"https://sea.hub:5000" | ||
] | ||
} | ||
], | ||
"exec-opts": [ | ||
"native.cgroupdriver=systemd" | ||
], | ||
"insecure-registries": ["0.0.0.0/0", "::/0"], | ||
"storage-driver": "overlay2", | ||
"storage-opts":["overlay2.override_kernel_check=true"], | ||
"live-restore": true, | ||
"data-root": "/var/lib/docker" | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.