Install Mikrotik CHR on Any Linux Ubuntu & Debian

1. Create new cloud VM (Ubuntu or Debian it does not matter…)

2. Boot, then mount tempfs to /tmp
mount -t tmpfs tmpfs /tmp/

3. Now we need to go https://www.mikrotik.com/download and download “Cloud Hosted Router” raw-image
cd /tmp
wget https://download.mikrotik.com/routeros/6.47.7/chr-6.47.7.img.zip

4. Next step, extract our image and flash it to HDD
unzip chr-6.47.7.img.zip
dd if=chr-6.47.7.img of=/dev/vda bs=4M oflag=sync

5. Now force reboot
echo 1 > /proc/sys/kernel/sysrq
echo b > /proc/sysrq-trigger
After reboot Mikrotik RouterOS will expand filesystem automatically.
You will see login prompt after that.

resource: https://medium.com/@kvaps/easy-way-for-install-mikrotiks-cloud-hosted-router-on-any-cloud-vm-fb1cf7302b85