mirror of
https://github.com/EvilFreelancer/docker-routeros.git
synced 2025-07-23 20:24:35 +02:00
documentation updated
This commit is contained in:
parent
cf17dc1425
commit
f511ab5d6d
1 changed files with 64 additions and 4 deletions
68
README.md
68
README.md
|
@ -1,11 +1,71 @@
|
||||||
# Mikrotik RouterOS in Docker
|
# Mikrotik RouterOS in Docker
|
||||||
|
|
||||||
|
This extrasmall image was created for tests purpose only, for example on
|
||||||
|
this project based unit testing of [routeros-api-php](https://github.com/EvilFreelancer/routeros-api-php) library.
|
||||||
|
|
||||||
|
If you need fully functional "RouterOS in Docker" for production usage
|
||||||
|
look at [VR Network Lab](https://github.com/plajjan/vrnetlab) project.
|
||||||
|
|
||||||
## How to use
|
## How to use
|
||||||
|
|
||||||
Build from `Dockerfile`
|
### Create your own `Dockerfile`
|
||||||
|
|
||||||
docker build . --tag ros
|
List of all avainble tags is [here](https://hub.docker.com/r/evilfreelancer/docker-routeros/tags/),
|
||||||
docker run -p 2222:22 -p 5900:5900 -ti ros
|
`latest` will be used by default.
|
||||||
|
|
||||||
Now you can connecto to your RouterOS container via VNC protocol
|
```dockerfile
|
||||||
|
FROM evilfreelancer/docker-routeros
|
||||||
|
ADD ["your-scripts.sh", "/"]
|
||||||
|
RUN /your-scripts.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
### Use image from docker hub
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker pull evilfreelancer/docker-routeros
|
||||||
|
docker run -d -p 22:22 -p 8728:8728 -p 8729:8729 -ti evilfreelancer/docker-routeros
|
||||||
|
```
|
||||||
|
|
||||||
|
### Use in docker-compose.yml
|
||||||
|
|
||||||
|
```yml
|
||||||
|
version: "2"
|
||||||
|
|
||||||
|
services:
|
||||||
|
|
||||||
|
routeros-legacy:
|
||||||
|
image: evilfreelancer/docker-routeros:6.42
|
||||||
|
restart: unless-stopped
|
||||||
|
ports:
|
||||||
|
- 12222:22
|
||||||
|
- 18728:8728
|
||||||
|
- 18729:8729
|
||||||
|
|
||||||
|
routeros-modern:
|
||||||
|
image: evilfreelancer/docker-routeros:6.43
|
||||||
|
restart: unless-stopped
|
||||||
|
ports:
|
||||||
|
- 22222:22
|
||||||
|
- 28728:8728
|
||||||
|
- 28729:8729
|
||||||
|
```
|
||||||
|
|
||||||
|
### Build from sources
|
||||||
|
|
||||||
|
For this you need download project and build everything from scratch:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://github.com/EvilFreelancer/docker-routeros.git
|
||||||
|
cd docker-routeros
|
||||||
|
docker build . --tag ros
|
||||||
|
docker run -d -p 22222:22 -p 8728:8728 -p 8729:8729 -ti ros
|
||||||
|
```
|
||||||
|
|
||||||
|
Now you can connect to your RouterOS container via VNC protocol
|
||||||
and via SSH on localhost 2222 port.
|
and via SSH on localhost 2222 port.
|
||||||
|
|
||||||
|
## List of exposed ports
|
||||||
|
|
||||||
|
For access via VNC: 5900
|
||||||
|
|
||||||
|
Default ports of RouterOS: 21, 22, 23, 80, 443, 8291, 8728, 8729
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue