From 1023560c356702e298237568bd4ac077b946043f Mon Sep 17 00:00:00 2001 From: Alexander Tebeiv Date: Sun, 21 Jun 2026 17:05:39 +0200 Subject: [PATCH] feat: add Docker setup for RouterOS and Mailpit services --- lab/README.md | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 lab/README.md diff --git a/lab/README.md b/lab/README.md new file mode 100644 index 0000000..ccc5f98 --- /dev/null +++ b/lab/README.md @@ -0,0 +1,51 @@ +# Local RouterOS test lab + +This lab runs MikroTik RouterOS CHR for development and manual tests. + +## Start the lab + +```sh +make start +make state +``` + +RouterOS can take up to two minutes to accept SSH connections on its first boot. +The `routeros-init` container retries during that period and exits after it applies the mail settings. + +## Access + +| Service | Address | +| --- | --- | +| Mailpit web interface | | +| RouterOS WebFig | | +| RouterOS WinBox | `localhost:18291` | +| RouterOS SSH | `localhost:12222` | +| RouterOS Telnet | `localhost:12223` | +| RouterOS API | `localhost:18728` | +| RouterOS API over TLS | `localhost:18729` | + +!! Use the RouterOS user `admin` with an empty password. Use this account inside the isolated lab. + +## Mailpit and ping + +Expect `ping mailpit` from RouterOS to time out. Docker DNS still resolves the `mailpit` name, and SMTP traffic can reach port `1025`. +The Docker and QEMU network path does not provide a useful ICMP health check for this service. + +Test SMTP from a RouterOS terminal: + +```routeros +/tool e-mail send to="lab@example.test" subject="lab test" body="mail works" +``` + +Open and check that Mailpit received the message. Use message delivery as the health check for this lab. + +## Usage + +```routeros +/system script run BackupAndUpdate +``` + +Follow the script log while it runs: +```routeros +/log print follow where message~"Bkp&Upd" +```