Copy and assign camera quality and wireless profiles, as well as mass-enable RTSP from a source template network, giving you faster and more consistent deployments.
Cisco Meraki MV cameras bring many benefits to organizations looking to deploy a video surveillance and analytics solution with ease, scalability and future-proofing. As customer deployments grow, it can be helpful to leverage programmability capabilities in the platform to further automate rollout and config management at scale, reducing the possibility of human error.
This tool simplifies the process of assigning quality, wireless and RSTP settings to camera deployments in one or multiple organizations, by leveraging user-defined tags:
The script has the added flexibility of allowing you to reference a network template as a source that resides in a different organization than the one where your target cameras currently exist on, permitting syncing configurations across organizations.
All of this is done without ever binding cameras to configuration templates, which allows you to keep completely separate firmware upgrade procedures across networks.
requirements.txt
qp-X-description
where X
is a unique number, and description
is a string that helps you identify the purpose of the profile, but that does not contain any additional -
dashes to the ones encasing X. Make sure each Wireless profile you create has a naming scheme that follows wp-X-description
where X
is a unique number, and description
is a string that helps you identify the purpose of the profile, but that does not contain any additional -
dashes to the ones encasing X.git clone https://github.com/Francisco-1088/merakiCamProfiler.git
config.py
api_key
in line 2Mkiconf.org_id
Mkiconf.locale_id
. Copy the number between the quotation marks, and prepend the string L_
right before it, and add it to the configuration file under src_net_id
. For example, if your template's ID is 34567897
, the value you should input in the configuration file is L_34567897
.dst_network_tag
to a tag of your preference. You may use camProfiler
if you want. This tag is used to identify networks that your script will deploy configurations to.dst_camera_tag
to a tag of your preference. You may use camProfiler
if you want. This tag is used to identify cameras that your script will deploy camera configurations to.rtsp_enable_tag
to a tag of your preference. You may use rtsp
if you want. This tag identifies cameras that will have RTSP enabled on them by the script.verbose
displays additional information about the data gathered from the source networks. supervised
prompts you before every configuration change, allowing you to skip it. console_logging
enables API log messages to appear in the console. You may set any of these to False
if you do not want this level of logging.pip install -r requirements.txt
from your terminalconfig.py
under dst_network_tag
config.py
under dst_camera_tag
camTagger.py
and cameras.csv
files to automatically tag your cameras. You have to modify the sample CSV with your own camera serials and the tags you wish to assign to them separated by commas as a string. You then execute this script with python camTagger.py
qp-X
prefix that your desired quality profile for this camera has. For example, if your source network has a quality profile named qp-1-highdef
, any cameras you want with this quality profile should carry the qp-1
tag.wp-X-Y-Z
format, where X, Y and Z are integers that identify a wireless profile number and their priority order, and where -Z is optional, but -X-Y are mandatory. For example, if you have 3 wireless profiles wp-1-psk
, wp-2-eap
, wp-3-psk2
, and a camera that needs to use wp-2-eap
as primary, wp-1-psk
as secondary and wp-3-psk
, then this tag should have wp-2-1-3
.The tagged cameras in the picture will receive the configurations of the quality profiles prefixed with qp-1
and qp-3
. For camera 4c:c8:a1:12:00:b9
, the assigned wireless profiles will be wp-1
and wp-2
, in that order. For camera 4c:c8:a1:11:00:eb
, the assigned wireless profiles will be wp-1
and wp-2
in that order.
NOTE: Quality Profiles and Wireless Profiles have the following restrictions:
qp-X
wp-X-Y
or wp-X-Y-Z
. The tag MUST reference at least two wireless profiles, and optionally a third, but never more than 3, so wp-1-2
and wp-2-3-1
are acceptable tags, but not wp-1-3-4-2
camProfiler
tag will be considered, so even if a camera has a qp-X
or wp-X-Y-Z
tag, but doesn't have the camProfiler
tag, that camera will not be operated onTag some these same cameras with your chosen rtsp_enabled_tag
(rtsp
by default). These cameras will have RTSP turned on for them by the script.
Run the script with python main.py
Note: If using the supervised=True
configuration in the config.py
file, every time the script will apply configuration changes it will prompt you to accept whether you want to continue or not. The prompt ONLY accepts Y
for continuing, or N
for skipping, and it is cap-sensitive. Any other input will break execution. A N
will return execution to the script before calling the function with the exception of Quality Profiles and Wireless Profiles. If you choose to skip either of these, the script will also break execution, as not creating these will cause problems when attempting to update Camera configurations.
Code Exchange Community
Get help, share code, and collaborate with other developers in the Code Exchange community.View Community