blob: c5a533c978a3c76e8893e31c4247b204558067d4 [file] [log] [blame]
Hansen, Tony (th1395)cf7f98a2021-12-02 20:42:43 +00001# ============LICENSE_START=======================================================
2# Copyright (c) 2017-2021 AT&T Intellectual Property. All rights reserved.
Ladue, David (dl3158)abb283c2018-03-14 14:01:36 -04003# ================================================================================
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15# ============LICENSE_END=========================================================
Ladue, David (dl3158)abb283c2018-03-14 14:01:36 -040016
17import argparse
18import array
19import asyncio
20import collections
21import datetime
22import errno
Ladue, David (dl3158)fb0aff82018-03-18 23:16:42 -040023import inspect
Ladue, David (dl3158)abb283c2018-03-14 14:01:36 -040024import json
25import logging
26import logging.handlers
27import os
28import pprint
29import re
30import requests
31import signal
32import socket
33import string
34import sys
35import time
36import traceback
Ladue, David (dl3158)fb0aff82018-03-18 23:16:42 -040037import trapd_settings
38import trapd_settings as tds
Ladue, David (dl3158)abb283c2018-03-14 14:01:36 -040039import unicodedata
40import uuid as uuid_mod
Ladue, David (dl3158)fb0aff82018-03-18 23:16:42 -040041from collections import Counter
42from onap_dcae_cbs_docker_client.client import get_config
43from pysnmp.carrier.asyncio.dgram import udp, udp6
Hansen, Tony (th1395)cf7f98a2021-12-02 20:42:43 +000044
Ladue, David (dl3158)fb0aff82018-03-18 23:16:42 -040045# from pysnmp.carrier.asyncore.dgram import udp
46from pysnmp.entity import engine, config
47from pysnmp.entity.rfc3413 import ntfrcv
48from pysnmp.proto.api import v2c
49from trapd_exit import cleanup_and_exit
50from trapd_file_utils import roll_all_logs, open_eelf_logs, roll_file, open_file, close_file
51from trapd_get_cbs_config import get_cbs_config
52from trapd_http_session import init_session_obj
53from trapd_logging import ecomp_logger, stdout_logger
54from trapd_logging import stdout_logger
55from trapd_runtime_pid import save_pid, rm_pid
Ladue, David (dl3158)abb283c2018-03-14 14:01:36 -040056
57install_reqs = parse_requirements("requirements.txt", session=PipSession())
58reqs = [str(ir.req) for ir in install_reqs]
59
60setup(
Hansen, Tony (th1395)cf7f98a2021-12-02 20:42:43 +000061 name="dcaegen2-collectors-snmptrap",
62 description="snmp trap receiver for ONAP docker image",
63 version="1.4.0",
Ladue, David (dl3158)abb283c2018-03-14 14:01:36 -040064 packages=find_packages(),
Hansen, Tony (th1395)cf7f98a2021-12-02 20:42:43 +000065 author="Dave L",
66 author_email="dl3158@att.com",
67 license="Apache 2",
68 keywords="",
69 url="",
70 install_requires=reqs,
Ladue, David (dl3158)abb283c2018-03-14 14:01:36 -040071)