EvilFreelancer / docker-routeros

Mikrotik RouterOS inside Docker container
https://hub.docker.com/r/evilfreelancer/docker-routeros/
MIT License
356 stars 127 forks source link

Initial configuration #7

Closed StefanYohansson closed 4 years ago

StefanYohansson commented 4 years ago

Hi, thank you for the repo, it is a really nice idea.

I have one doubt regarding the RouterOS initial configuration, I have one docker-compose and I want to run some command or something in order to configure it (configure ppoe and radius). do you have any way or idea of how to run a script to initially configure the Mikrotik?

isprouter:
                image: evilfreelancer/docker-routeros
                restart: unless-stopped
                cap_add:
                        - NET_ADMIN
                devices:
                        - /dev/net/tun
                ports:
                        - "2222:22"
                        - "2223:23"
                        - "8728:8728"
                        - "8729:8729"
                        - "8291:8291"
                networks:
                        static-network:
                                ipv4_address: 172.20.128.5
EvilFreelancer commented 4 years ago

Hello! @StefanYohansson!

This project was created because for other my project https://github.com/EvilFreelancer/routeros-api-php was need to write unit tests.

You may look at simple preconf script which executed each time when source code of library is changed.

Probably this script and library will help you :)

StefanYohansson commented 4 years ago

Yeah, that helped so much! thank you

EvilFreelancer commented 4 years ago

Glad to help :)