aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Dockerfile4
-rw-r--r--setup.py35
2 files changed, 2 insertions, 37 deletions
diff --git a/Dockerfile b/Dockerfile
index b1229b2..c8c8ae5 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -14,6 +14,8 @@ EXPOSE 162
# Copy the current directory contents into the container at ${APPDIR}
COPY ./bin/ ./bin/
COPY ./etc/ ./etc/
+COPY requirements.txt ./
+RUN pip install -r requirements.txt
RUN mkdir -p ${APPDIR}/data \
&& mkdir -p ${APPDIR}/logs \
@@ -25,8 +27,6 @@ RUN mkdir -p ${APPDIR}/data \
&& chmod 500 ${APPDIR}/etc \
&& chmod 500 ${APPDIR}/bin/snmptrapd.sh
-RUN python setup.py install
-
USER ${APPUSER}
VOLUME ${APPDIR}/logs
diff --git a/setup.py b/setup.py
index 5a12f10..54b785d 100644
--- a/setup.py
+++ b/setup.py
@@ -17,44 +17,9 @@
#
# ECOMP is a trademark and service mark of AT&T Intellectual Property.
-import argparse
-import array
-import asyncio
-import collections
-import datetime
-import errno
-import inspect
-import json
-import logging
-import logging.handlers
import os
-import pprint
-import re
-import requests
-import signal
-import socket
import string
import sys
-import time
-import traceback
-import trapd_settings
-import trapd_settings as tds
-import unicodedata
-import uuid as uuid_mod
-from collections import Counter
-from onap_dcae_cbs_docker_client.client import get_config
-from pysnmp.carrier.asyncio.dgram import udp, udp6
-# from pysnmp.carrier.asyncore.dgram import udp
-from pysnmp.entity import engine, config
-from pysnmp.entity.rfc3413 import ntfrcv
-from pysnmp.proto.api import v2c
-from trapd_exit import cleanup_and_exit
-from trapd_file_utils import roll_all_logs, open_eelf_logs, roll_file, open_file, close_file
-from trapd_get_cbs_config import get_cbs_config
-from trapd_http_session import init_session_obj
-from trapd_logging import ecomp_logger, stdout_logger
-from trapd_logging import stdout_logger
-from trapd_runtime_pid import save_pid, rm_pid
install_reqs = parse_requirements("requirements.txt", session=PipSession())
reqs = [str(ir.req) for ir in install_reqs]