feat: multi-distro support and tagged golden snapshots
Add Alpine, Debian, and Ubuntu rootfs support to `init [distro]`. Golden snapshots are now namespaced under `golden/<tag>/` so multiple baselines can coexist. `spawn [tag] [N]` selects which snapshot to clone from. Systemd-based distros (Debian, Ubuntu) get a fc-net-init systemd unit; Alpine keeps its inittab-based init. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
21
test_mmds.sh
Normal file
21
test_mmds.sh
Normal file
@@ -0,0 +1,21 @@
|
||||
#!/bin/bash
|
||||
sock="/tmp/fctest.sock"
|
||||
rm -f "$sock"
|
||||
firecracker --api-sock "$sock" &
|
||||
FCPID=$!
|
||||
sleep 1
|
||||
|
||||
# Configure MMDS backend
|
||||
curl --unix-socket "$sock" -i -X PUT "http://localhost/mmds/config" \
|
||||
-H "Accept: application/json" -H "Content-Type: application/json" \
|
||||
-d '{"version": "V1", "network_interfaces": ["1"], "ipv4_address": "169.254.169.254"}'
|
||||
|
||||
# Put data
|
||||
curl --unix-socket "$sock" -i -X PUT "http://localhost/mmds" \
|
||||
-H "Accept: application/json" -H "Content-Type: application/json" \
|
||||
-d '{"ip": "10.0.0.2", "gw": "10.0.0.1", "dns": "1.1.1.1"}'
|
||||
|
||||
# Read data
|
||||
curl --unix-socket "$sock" -i -X GET "http://localhost/mmds"
|
||||
|
||||
kill $FCPID
|
||||
Reference in New Issue
Block a user