11 Commits
Author SHA1 Message Date
Dreaded_X 0e1c2f20b3 fix: Only connections from localhost are allowed
Committed / committed (pull_request) Canceled after 19s
CI / prek (pull_request) Canceled after 38s
CI / cargo shear (pull_request) Canceled after 38s
2026-10-04 05:39:28 +02:00
Dreaded_X f9da1d907b feat: Added wrapper crate for including ipxe binaries 2026-10-04 05:39:26 +02:00
Dreaded_X 4bea843e53 feat: Serve never returns 2026-10-04 05:39:25 +02:00
Dreaded_X 158de17328 feat!: Added command to serve config files over tftp
This is a breaking change as the return type of cluster.nodes has
changed, resulting in old templates potentially no longer working.
2026-10-04 05:39:24 +02:00
Dreaded_X c20835f087 feat: Make tftp serve callback async 2026-10-04 05:39:23 +02:00
Dreaded_X 101d690285 refactor: Deduplicate paths 2026-10-04 05:39:22 +02:00
Dreaded_X 1dae62846b feat: Retain context 2026-10-04 05:39:20 +02:00
Dreaded_X 231e61d4ad feat: Configs are captured in a string first 2026-10-04 05:39:19 +02:00
Dreaded_X 63c014fd3f feat: Improve concurrency 2026-10-04 05:39:18 +02:00
Dreaded_X bcf716038e feat: Make application async 2026-10-04 05:39:17 +02:00
Dreaded_X 9440ede0ab feat: Added ftfp server implementation 2026-10-04 05:39:16 +02:00
2 changed files with 3 additions and 4 deletions
-1
View File
@@ -120,7 +120,6 @@ async fn main() -> Result<(), Error> {
async move { async move {
const IPXE_PATTERN: &str = "ipxe/"; const IPXE_PATTERN: &str = "ipxe/";
if let Some(filename) = filename.strip_prefix(IPXE_PATTERN) { if let Some(filename) = filename.strip_prefix(IPXE_PATTERN) {
println!("Looking for iPXE binary: {filename}");
Some(IPXE_DIR.get_file(filename)?.contents().to_owned()) Some(IPXE_DIR.get_file(filename)?.contents().to_owned())
} else if let Some(caps) = re.captures(&filename) { } else if let Some(caps) = re.captures(&filename) {
let cluster = &caps["cluster"]; let cluster = &caps["cluster"];
+3 -3
View File
@@ -37,7 +37,7 @@ where
F: Fn(&str) -> Fut, F: Fn(&str) -> Fut,
Fut: Future<Output = Option<Vec<u8>>>, Fut: Future<Output = Option<Vec<u8>>>,
{ {
let socket = UdpSocket::bind("127.0.0.1:0").await?; let socket = UdpSocket::bind("0.0.0.0:0").await?;
println!( println!(
"{src}: Connecting from {}", "{src}: Connecting from {}",
socket.local_addr().expect("Socket is bound") socket.local_addr().expect("Socket is bound")
@@ -85,7 +85,7 @@ where
let mut timeout = 0; let mut timeout = 0;
loop { loop {
// Send the first byte // Send the first chunk
if let Some((index, chunk)) = chunk { if let Some((index, chunk)) = chunk {
Packet::data((index + 1) as u16, chunk) Packet::data((index + 1) as u16, chunk)
.send_to(&socket, &src) .send_to(&socket, &src)
@@ -150,7 +150,7 @@ where
F: Fn(&str) -> Fut + Clone + Send + 'static, F: Fn(&str) -> Fut + Clone + Send + 'static,
Fut: Future<Output = Option<Vec<u8>>> + Send + 'static, Fut: Future<Output = Option<Vec<u8>>> + Send + 'static,
{ {
let socket = UdpSocket::bind("127.0.0.1:69").await?; let socket = UdpSocket::bind("0.0.0.0:69").await?;
println!("Server started"); println!("Server started");
loop { loop {