TL;DR: Just my current status.

On 24.02.24 22:47, John Nielsen wrote:
1) AWS EC2 + cloud-init. The FreeBSD Project publishes AMIs for every release 
(again, thanks cperciva). You can launch an EC2 instance from one of those with 
a few clicks. You can additionally assign an IAM role to the instance to give 
it permission to write to an S3 bucket and drop a script in the user-data for 
the instance to run when it boots. The script could download the Python code to 
be run, run it, and upload the results to S3 all non-interactively.

With a couple hours’ work you could adapt the stock image to add any missing 
dependencies and disable unneeded drivers and services to speed the boot, then 
snapshot that and use your custom image for future runs.

You could also easily manage the whole thing with Terraform. Copy/paste the 
infrastructure as code templates and tweak the variables to get an easily 
repeatable system.

Ah, I didn't mention that. The tests are for running locally.
The overall project is for a home appliance, so no cloud.

2) KVM + libvirt on whatever Linux host(s) you have available. The VM-IMAGES 
released by the Project include qcow volumes. You might need to tweak the image 
to do your custom script(s) at startup (though the image may also have 
cloud-init if your environment supports it) but qcow does support snapshots as 
well and the whole thing should have low boot times.

That was my second approach :-)
It turned out to have various roadbumps (mostly lack of knowledge/experience on my side, no doubts about that).

I'm currently going back to my first approach, Vagrant, but diving into writing my own Vagrantfile. I understand that's easy enough for somebody without deep knowledge of KVM/libvirt, so I'll see.

Regards,
Jo

Reply via email to