ASCii VM Scale Set Dashboard
Dashboard to show and configure Azure VM Scale Set status, properties... Version 2.0 New Features:
Simple and easy to start VMs...
Watch live graphs of Insights Telemetry data, logs and more!
Fear nothing, the global map is still here...
USING DOCKER (Ubuntu):
If you don't have docker installed, first execute: sudo apt-get install -y docker.io
With docker installed:
Fill in the asciivmssdashboard.json config file with your custom values... 8. export TERM=screen; export PYTHONDONTWRITEBYTECODE=1; ./console.py
OR:
After you have the application installed, you will need: For DEMO (No real vmss config)
For use it in a Real VMSS Dashboard
Register an Azure application, create a service principal, and get your tenant id. See "Using ASCiiVMSSDashboard".
Put in values for your application along with your resource group name and VM Scale Set name in /home/your-username/asciivmssdashboard.json file.
If you want to watch the Insights Telemetry Graphs (for the Azure Service), you will need to configure Azure Insights. See "Using Application Insights Telemetry Data".
You can use a custom URL (e.g.: Your own Telemetry API). For that, you will need to have an Telemetry API that provides the metrics (e.g.: JSON), similar to Azure Application Insights.
NOTE: If you want to use custom telemetry APIs Services, leave the 'insightsUrl' config option 'empty'. If the insightsUrl is configured, it will have precedence and ASCiiVMSSDashboard will use it in conjuction with the metric (e.g.: insightsOneMetric) configured. If it is not configured, and (for example): insightsOne is enabled, the insightsOneUrl will be used to get the first metric.
Run (on Linux): asciivmssdashboard or (on Windows): path_to_python path_to_asciivmssdashboard_script.
To Exit the Console, just hit: Ctrl+C or use the command: 'quit' (for a 'clean' exit, we will wait for the update threads to finish). In the Windows Platform you can just use the command: 'quit' for now (See "CAVEATS" bellow).
Subtitle/Captions should be enabled by default, but if not, enable them to follow the action (English and Portuguese BR available). Don't forget to subscribe to the channel for updates...
ASCiiVMSSDashboard (v1.4) - Screencast
ASCiiVMSSDashboard (v1.4) - running natively on Android (Youtube Version)
ASCiiVMSSDashboard (v1.0) - Screencast
Enjoy some code and loud music!
Release Version 1.8 has animations for the Windows (Continents), Azure Regions updated,, and change of the color for the regions on map for better visibility. Other than that, I changed the character for representing the regions to be a 'block' and not just a space, so I could add bright color and have it highlighted (just works for foreground, so space was not working).
Version 1.6 features Telemetry data on graphs integrated on the ASCiiVMSSDashboard now is fully integrated and flexible.
The Version 1.4 brings many new features and commands for the ASCiiVMSSDashboard utility. This version has an option to create a log file with many useful information that can be watched live directly in the ASCiiVMSSDashboard. It's very simple to display the log on the screen, just issue the command: 'log'. Using the console config file, you can set the log level (e.g.: INFO, DEBUG, and etc).
One of the key features of this new version of the ASCiiVMSSDashboard is the ability to see in real time two instrumentation graphs. You can eanble this feature on the asciivmssdashboard.json file, and set the title of the graph and the URL that the console will use to gather the metrics. The console will just do a HTTP GET on each URL and expect to receive an 'number' to plot on the graphs.
There is an option to enable one, two or disable both graphs. In the future I plan to integrate with the Azure Application Insights, and so we should be able to select any of the metrics configured on the platform. Stay tuned!
These are the PROMPT, General Info, and System Info windows:
Multiple pages for visualization of all your Virtual Machines (each page shows 100 VM's). Here you can see a screenshot showing the first page:
Next, we can see the second page:
The console will show you your subscription/region usage and limits:
The ASCiiVMSSDashboard can run on Python 2.x or 3.x versions, and you will see the version it is running at the top title:
In case of any errors, you will be able to see the messages on the LOG Window, and also as a specific message in the main window:
###TIP #1: To not create the .pyc files, I use the following (on Linux): export TERM=screen; export PYTHONDONTWRITEBYTECODE=1; ./console.py. IMPORTANT: I use 'screen' terminal and it was the best emulation I found to run curses application. You can try other terminals that you have the best experience or compatibility in your system (e.g.: TERM=xterm, TERM=xterm-color, etc).
###TIP #2: I have used the console with no issues using a refresh interval of 60 seconds. If you use a more 'agressive' update interval, keep one eye at the last-update registered at the top-left of the dashboard window and/or in the log window (e.g.: 'log'), to see if the console is stil running. If you notice it stopped, you should see the 'ERROR' window described above, and the console should resume in 30 seconds. if the log has information about AZURE API 'throttling", you will need to restart the ASCiiVMSSDashboard (with a bigger inteval)...
###TIP #3: As we wait for the threads to finish as you hit 'Ctrl+C' or 'quit' (to exit), the time you will wait to get your prompt back will be proportional to you refresh interval (e.g.: max='INTERVAL'). You can change the update interval in the 'asciivmssdashboard.json' file.
To issue commands for the Azure Resource Manager API to add and/or delete virtual machines from the Scale Set, you just need to type ':'. After that, the cursor will appear at (PROMPT window), and you will be able to enter commands. To see a help window just type ':' (to activate the command PROMPT), and 'help'. To hide the help window, just type 'help' again.
REMEMBER: To activate the prompt window, type: ':'
Commands (v1.4):
##PDCURSES
To use this app (and in general to access Azure Resource Manager from a program without going through 2 factor authentication), you need to register your application with Azure and create a "Service Principal" (an application equivalent of a user). Once you've done this you'll have 3 pieces of information: A 'tenant ID', an 'application ID', and an 'application secret'. You will use these to populate the 'asciivmssdashboard.json' file.
For more information on how to get this information go here: Authenticating a service principal with Azure Resource Manager. See also: Azure Resource Manager REST calls from Python.
If you want to have integrated graphs on the ASCiiVMSSDashboard directly from Azure Application Insights, you should follow the steps described here: App Insights I and App Insights II.
Example JSON:
{
"value": {
"request/totalCount": {
"values": "30"
}
}
}