Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 7 additions & 9 deletions parts/k8s/cloud-init/artifacts/cse_config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,13 @@ configureEtcd() {
}
configureChrony() {
sed -i "s/makestep.*/makestep 1.0 -1/g" /etc/chrony/chrony.conf
echo "refclock PHC /dev/ptp0 poll 3 dpoll -2 offset 0" >> /etc/chrony/chrony.conf
cat > /etc/udev/rules.d/99-ptp_hyperv.rules << EOF
ACTION!="add", GOTO="ptp_hyperv"
SUBSYSTEM=="ptp", ATTR{clock_name}=="hyperv", SYMLINK += "ptp_hyperv"
LABEL="ptp_hyperv"
EOF
udevadm control --reload
udevadm trigger --subsystem-match=ptp --action=add -v
}
ensureChrony() {
systemctlEnableAndStart chrony || exit {{GetCSEErrorCode "ERR_SYSTEMCTL_START_FAIL"}}
Expand Down Expand Up @@ -336,16 +342,9 @@ ensureContainerd() {
}

ensureNoBridgeDocker0 () {
# Define the name of the bridge you want to check and potentially delete
BRIDGE_NAME="docker0"
# Check if the bridge exists
if ip link show "$BRIDGE_NAME" &> /dev/null; then
# The bridge exists, so delete it
echo "Deleting bridge network $BRIDGE_NAME"
retrycmd 120 5 25 ip link delete "$BRIDGE_NAME" type bridge || exit {{GetCSEErrorCode "ERR_REMOVE_DOCKER_BRIDGE_FAIL"}}
else
# The bridge does not exist
echo "Bridge network $BRIDGE_NAME does not exist"
fi
}

Expand Down Expand Up @@ -618,7 +617,6 @@ configAzurePolicyAddon() {
{{end}}

configAddons() {
echo "configAddons placeholder, keep"
{{if IsClusterAutoscalerAddonEnabled}}
if [[ ${CLUSTER_AUTOSCALER_ADDON} == true ]]; then
configClusterAutoscalerAddon
Expand Down
17 changes: 7 additions & 10 deletions pkg/engine/templates_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.