ArRosid / ztp-mikrotik

Zero Touch Provisioning on Mikrotik

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ztp-mikrotik

Zero Touch Provisioning on Mikrotik

This repository contain python script to doing Zero Touch Provisioning on Mikrotik

Topology

This repository is tested using this Topology

Requirement

To run this repository, you need some python library installed on your computer.
  • Python 3.6.5
  • flask
  • paramiko
  • telepot
  • python-mysqldb

Setup

  1. Create Telegram bot, this telegram bot will used to notify us if the provisioning on Mikrotik completed. You can follow tutorial on https://docs.microsoft.com/en-us/azure/bot-service/bot-service-channel-connect-telegram?view=azure-bot-service-4.0
  2. Clone this repository
  3. Install requirement library
    • virtualenv -p python3 venv
    • source venv/bin/activate
    • pip install -r requirement
    • sudo apt-get install python-mysqldb
  4. Edit ztp_mikrotik.py. Fill the 'your_token' and 'your_chat_id'
  5. Run the python script
    • python3 ztp_mikrotik.py
  6. Configure PPPoE Server on ISP
  7. Add ppp_script_on_up.txt to the on UP script in the PPP Server Profile. Modify the 'your_flask_server_ip_address'. Make sure your flask server can reach PPPoE Client. May be you need to add static route to the PPPoE Client via PPPoE Server
  8. Configure PPPoE Client on Customer, and see that you will reciev Telegram notification and the customer is provisioned automatically

About

Zero Touch Provisioning on Mikrotik

License:MIT License


Languages

Language:Python 100.0%