From 9c3b13ea1bffb8890776bee51b0e5af32cef1688 Mon Sep 17 00:00:00 2001 From: SANDEEP KUMAR JAISAWAL Date: Fri, 4 Nov 2022 12:47:12 +0530 Subject: [PATCH] Adding Dockerfile and container tag for build process Issue-Id: AIMLFW-2 Signed-off-by: SANDEEP KUMAR JAISAWAL Change-Id: I308a9b1eb99646c6159bbcb22bd0a8faedcc4205 --- Dockerfile | 39 +++++++++++++++++++++++++++++++++++++++ container-tag.yaml | 21 +++++++++++++++++++++ 2 files changed, 60 insertions(+) create mode 100644 Dockerfile create mode 100644 container-tag.yaml diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..acc8282 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,39 @@ +# ================================================================================== +# +# Copyright (c) 2022 Samsung Electronics Co., Ltd. All Rights Reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ================================================================================== +#Base Image +FROM python:3.8 + +# location in the container +ENV TA_DIR /home/app/ +# Install dependencies +RUN apt-get update && apt-get install -y \ + python3-pip +RUN apt-get install -y apt-utils + + +# Copy sources into the container +COPY tm/ ${TA_DIR}/tm +COPY tm/requirements.txt ${TA_DIR} +WORKDIR ${TA_DIR} + +RUN pip3 install . +RUN pip3 install -r requirements.txt + +#Expose the ports +EXPOSE 5050 + diff --git a/container-tag.yaml b/container-tag.yaml new file mode 100644 index 0000000..d889f62 --- /dev/null +++ b/container-tag.yaml @@ -0,0 +1,21 @@ + # ================================================================================== +# +# Copyright (c) 2022 Samsung Electronics Co., Ltd. All Rights Reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# ================================================================================== + # The Jenkins job requires a tag to build the Docker image. + # Global-JJB script assumes this file is in the repo root. + --- + tag: 1.0.0 \ No newline at end of file -- 2.16.6