ishiland / ArcGIS-License-Tracker

A Flask application for Esri concurrent use license tracking
MIT License
4 stars 4 forks source link
arcgis esri license license-management python

ArcGIS License Tracker

A web application to display current and historical license usage from a concurrent use (floating) license server.

App Preview

Features

Requirements

Getting Started

  1. Clone the repo

    > git clone https://github.com/ishiland/arcgis-license-tracker.git
    > cd arcgis-license-tracker
  2. Initialize and activate a virtualenv:

    > python -m virtualenv venv
    > venv\Scripts\activate
  3. Install the dependencies:

    > pip install -r requirements.txt
  4. In app/arcgis_config.py, configure the following:

    • license_servers - List of license servers to track. The default port is 27000.
    • lm_util - Path to your lmutil.exe.
  5. Initialize the database

    Initialize the database using:

    > python manage.py recreate_db
  6. Test your license server configuration:

    > python manage.py read_once
  7. Run the development server:

    > python manage.py runserver
  8. Navigate to http://localhost:5000

Production

After successfully testing in development, set the FLASK_ENV variable to production then initialize a production database using python manage.py recreate_db.

Task Scheduler

Configure Windows Task Scheduler to update the license data. The following settings should work for most cases:

In 'General' check 'Run Whether user is logged on'.

The 'Trigger' should be set to run between 1 and 5 minutes. Make sure to check the 'Enabled' box.

The 'Action' should look similar to this:

Deploy

Deploy to a production web server. Here are some helpful guides and tools for deploying to IIS:

There is also a sample web.config for reference included in this repo. A summary of other deployment options here.

Tests

Tests can be ran using python manage.py test

Further Thoughts