Dec
09
2018
0

How to setup a Python-Jenkins API connection with Python 3

I’m working a project to create Python program that scrapes jobs from a Jenkins server, with the end goal of storing them in a Mongo NoSQL database as an archive.  At work we have more than a dozen build servers that will ultimately will be consolidated to a few.  My plan(since we are moving to […]

Nov
20
2017
0

Ansible: How to automate past “Initial setup of CentOS Linux 7” message

  I recently came across an annoying issue with CentOS 7 setup.  I started with a minimal install, completed my installation(including mate desktop) and rebooted.  When I attached to the console of the newly minted VM I discovered it was stuck at a license prompt.  To avoid this issue…

Sep
23
2017
2

How to setup a Centurylink IQ SIP Trunk for Asterisk

I recently struggled to install a Centurylink SIP trunk.  Our rep could only provided us with Cisco configuration instructions.  From there we had to decipher the appropriate settings in Asterisk.  If you are reading this post you are probably in serious trouble right now.  Don’t worry!  Take a deep breath and keep reading!  This is […]

Aug
20
2017
0

How to block outside IP addresses with firewalld on CentOS 7

There are situations were specific IP addresses or ranges may need to be blocked.  In my case I have SIP hackers trying to brute force a publicly exposed Asterisk server.  I don’t have control over the exterior gateway or firewalls between the server and public internet.  So in this case I have to specifically block […]

Written by mattb in: Linux | Tags: , , , ,
Aug
01
2017
0

BASH script to cp/mv files of a certain date

I have a client that owns a high volume call center.  For quality assurance and training purposes they record all the calls.  Periodically the volume of recorded calls grows to the point that it slows down the NFS share to the Queuematrics call center software(Tomcat app).  I wrote a script that finds files by time […]

Jul
06
2017
0

How to Install mysql-connector for Python

For several months Python mysql-connector has been broken when attempting a install from pip.  In truth I’ve only tried Python 3, CentOS 6/7 and Fedora 21; in fact, this could be a more wide spread.  The simple solution is to install an earlier version.  The purpose of this post is to be a quick reminder […]

Jul
03
2017
0

How to connect Asterisk SIP Clients over Duel Layers of NAT

A common problem with SIP is it’s difficulty handling NAT(especially over multiple layers).  A common symptom is no audio stream.  The Asterisk CLI  shows a successful call connection succeeding followed by an error in /var/log/asterisk/messages:

Jun
26
2017
0

How to handle Python 3 Fabric exceptions with a Decorator

Python’s Fabric module is an easy and efficient way for task based automation.  I use it to automate the installation of VoIP phone systems on CentOS 6/7.  In a nut shell, Fabric executes shell commands over SSH.  It also can be used to automate local tasks.  The purpose of this article is to highlight the […]

Jun
21
2017
0

Automate Git Repository Setup with Python & Fabric

I love Git.  I find Git to be an intuitive way to track many versions between many systems.  Now all my default config files and scripts utilize Git.  However, logging into a server and creating the Git repo, then cloning it is a number of steps that detracts from getting work done.   This tutorial […]

Jun
08
2017
0

How to Install and Configure Basic Git Server on CentOS 6

Git has changed my life.  I’m not exaggerating.  I work with a lot of ‘one off’ scripts (BASH, PHP, and Python).  They are spread out among systems and developed from my workstation and(sometimes) laptop.  I spent 15 years keeping multiple versions and copies of the same scripts spread between systems.  Looking back it seems Crazy! […]

Written by mattb in: Automation,Linux | Tags: , , , , ,