Initialize /config from /etc, except for existing files (like bind-mounts). Move to using /config in VPP, even though there is a backwards compat symlink from /etc/{frr,bird,vpp} to /config

This commit is contained in:
2026-04-02 00:16:49 +02:00
parent 039d09d358
commit d8369e2c10
6 changed files with 17 additions and 11 deletions

View File

@@ -1,12 +1,13 @@
mpls table add 0
set ip neighbor-config ip4 age 900
set ip neighbor-config ip6 age 900
lcp lcp-auto-subint off
lcp default netns dataplane
lcp lcp-sync on
lcp lcp-sync-unnumbered on
lcp param del-static-on-link-down on
lcp param del-dynamic-on-link-down on
exec /etc/vpp/config/manual-pre.vpp
exec /etc/vpp/config/clab.vpp
exec /etc/vpp/config/vppcfg.vpp
exec /etc/vpp/config/manual-post.vpp
lcp lcp-auto-subint off
exec /config/vpp/config/manual-pre.vpp
exec /config/vpp/config/clab.vpp
exec /config/vpp/config/vppcfg.vpp
exec /config/vpp/config/manual-post.vpp

View File

@@ -9,7 +9,7 @@ unix {
cli-prompt vpp-clab#
cli-no-pager
poll-sleep-usec 100
exec /etc/vpp/bootstrap.vpp
exec /config/vpp/bootstrap.vpp
}
api-trace {

View File

@@ -19,6 +19,13 @@ sed -i -e 's,^#PermitRootLogin prohibit-password,PermitRootLogin yes,' /etc/ssh/
sed -i -e 's,^root:.*,root:$y$j9T$kG8pyZEVmwLXEtXekQCRK.$9iJxq/bEx5buni1hrC8VmvkDHRy7ZMsw9wYvwrzexID:20211::::::,' /etc/shadow
/etc/init.d/ssh start
echo "Initializing /config"
for dir in vpp bird frr; do
rsync -av --ignore-existing /etc/$dir/ /config/$dir/
rm -rf /etc/$dir/
ln -s /config/$dir /etc/$dir
done
if [ "$BIRD_ENABLED" == "true" ]; then
echo "Starting Bird in $NETNS"
mkdir -p /run/bird /var/log/bird