diff --git a/opensearch-maps-server/Dockerfile b/opensearch-maps-server/Dockerfile index 86e05c6..47c2988 100644 --- a/opensearch-maps-server/Dockerfile +++ b/opensearch-maps-server/Dockerfile @@ -3,9 +3,12 @@ FROM amazonlinux:2 WORKDIR /usr/src/app RUN curl -sL https://rpm.nodesource.com/setup_16.x | bash - && \ - yum install -y nodejs wget tar gzip && \ + yum install -y nodejs wget tar gzip unzip python37 && \ yum clean all +RUN pip3 install --no-cache --upgrade \ + "requests>=2.18.4,<=2.22.0" + COPY package*.json ./ RUN npm install COPY . . @@ -19,4 +22,12 @@ RUN mkdir -p public/vectors/data && \ COPY entrypoint.sh . RUN chmod +x entrypoint.sh ENTRYPOINT ["./entrypoint.sh"] + EXPOSE 8080 + +RUN wget -O oss_compliance.zip https://aws-dlinfra-utilities.s3.amazonaws.com/oss_compliance.zip \ + && unzip oss_compliance.zip \ + && chmod +x oss_compliance/generate_oss_compliance.sh \ + && oss_compliance/generate_oss_compliance.sh /usr/src/app python3 \ + && cp oss_compliance/python_packages/piplicenses/PACKAGES_LICENSES_JSON.json PACKAGES_LICENSES_JSON.json \ + && rm -rf oss_compliance* \ No newline at end of file