build: add Docker support

This commit is contained in:
2024-03-22 16:13:30 +01:00
parent bb66931250
commit d43455a1d9
5 changed files with 93 additions and 7 deletions

View File

@@ -36,7 +36,7 @@ namespace crypto_key
if (!utils::io::write_file("./private.key", key.serialize()))
{
throw std::runtime_error("Failed to write server key!");
console::error("Failed to write server key!");
}
console::info("Generated cryptographic key: %llX", key.get_hash());

View File

@@ -142,8 +142,14 @@ void kill_list::write_to_disk()
stream << entry.ip_address_ << " " << entry.reason_ << "\n";
}
utils::io::write_file(kill_file, stream.str(), false);
console::info("Wrote %s to disk (%zu entries)", kill_file, entries.size());
if (utils::io::write_file(kill_file, stream.str(), false))
{
console::info("Wrote %s to disk (%zu entries)", kill_file, entries.size());
}
else
{
console::error("Failed to write %s!", kill_file);
}
});
}