This commit is contained in:
Thales Maciel 2026-01-26 18:05:54 -03:00
parent 87a04e4076
commit dba2f327f5
No known key found for this signature in database
GPG key ID: 33112E6833C34679
3 changed files with 3 additions and 3 deletions

2
.gitignore vendored
View file

@ -5,4 +5,4 @@ state/
*.tgz
*.squashfs*
squashfs-root/
rootfs.ext4
rootfs*

Binary file not shown.

4
run.sh
View file

@ -21,12 +21,13 @@ BR_IP="172.16.0.1"
CIDR="24"
VM_ID="$(date +%s)-$$"
VM_TAG="${VM_ID##*-}"
VM_DIR="$STATE/vm-$VM_ID"
mkdir -p "$VM_DIR"
API_SOCK="$VM_DIR/firecracker.sock"
LOG_FILE="$VM_DIR/firecracker.log"
TAP_DEV="tap-fc-$VM_ID"
TAP_DEV="tap-fc-$VM_TAG"
# Allocate guest IP
NEXT_IP_FILE="$STATE/next_ip"
@ -132,5 +133,4 @@ log "vm started successfully"
log "guest ip: $GUEST_IP"
log "ssh: ssh -i \"$SSH_KEY\" root@$GUEST_IP"
log "logs: $LOG_FILE"
log "done"