#!/usr/bin/env python
# Copyright (c) 2013 Arista Networks, Inc.  All rights reserved.
# Arista Networks, Inc. Confidential and Proprietary.

"""The XMPP agent binary script.

This is the agent binary script to be executed by ProcMgr.
"""

import os

# This script it named Xmpp so Pylint thinks we are importing
# ourself below; however, since Python 2.x imports from the
# local directory last, this is really importing the Xmpp.py
# from /usr/lib/python2.*/site-packagaes/.

# pylint: disable-msg=W0406
import Xmpp
# pylint: enable-msg=W0406

sysname = os.environ.get( "SYSNAME" )
if sysname:
   os.environ[ "AAA_SYSNAME" ] = sysname
del sysname

# The Xmpp module really does have a 'main' function, but
# pylint believes its 'Xmpp' reference is this module.

# pylint: disable-msg=E1101
Xmpp.main()
