| garciadeblas | 7b53d26 | 2022-11-04 23:18:48 +0100 | [diff] [blame] | 1 | ####################################################################################### |
| 2 | # Copyright ETSI Contributors and Others. |
| 3 | # |
| 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 |
| 13 | # implied. |
| 14 | # See the License for the specific language governing permissions and |
| 15 | # limitations under the License. |
| 16 | ####################################################################################### |
| 17 | |
| 18 | FROM apache/airflow:2.3.0-python3.8 |
| 19 | USER root |
| 20 | RUN DEBIAN_FRONTEND=noninteractive apt-get --yes update && \ |
| 21 | DEBIAN_FRONTEND=noninteractive apt-get --yes install \ |
| 22 | gcc git python3 python3-dev python3-venv python3-pip \ |
| 23 | python3-setuptools wget && \ |
| 24 | python3 -m pip install -U pip build |
| 25 | |
| garciadeblas | 9f58633 | 2022-11-28 23:54:26 +0100 | [diff] [blame^] | 26 | USER airflow |
| 27 | |
| garciadeblas | 7b53d26 | 2022-11-04 23:18:48 +0100 | [diff] [blame] | 28 | ARG PYTHON3_OSM_COMMON_URL |
| 29 | ARG PYTHON3_OSM_NGSA_URL |
| 30 | RUN curl $PYTHON3_OSM_COMMON_URL -o osm_common.deb |
| garciadeblas | 0cdfb57 | 2022-11-11 10:24:51 +0100 | [diff] [blame] | 31 | RUN curl $PYTHON3_OSM_NGSA_URL -o osm_ngsa.deb |
| garciadeblas | 9f58633 | 2022-11-28 23:54:26 +0100 | [diff] [blame^] | 32 | RUN mkdir /tmp/osm |
| 33 | RUN dpkg-deb -x osm_common.deb /tmp/osm |
| 34 | RUN dpkg-deb -x osm_ngsa.deb /tmp/osm |
| 35 | |
| 36 | RUN mv /tmp/osm/usr/lib/python3/dist-packages/* /home/airflow/.local/lib/python3.8/site-packages/ |
| 37 | RUN rm -rf /tmp/osm |
| garciadeblas | 7b53d26 | 2022-11-04 23:18:48 +0100 | [diff] [blame] | 38 | |
| 39 | RUN pip3 install \ |
| garciadeblas | 9f58633 | 2022-11-28 23:54:26 +0100 | [diff] [blame^] | 40 | -r /home/airflow/.local/lib/python3.8/site-packages/osm_common/requirements.txt \ |
| 41 | -r /home/airflow/.local/lib/python3.8/site-packages/osm_ngsa/requirements.txt |
| garciadeblas | 7b53d26 | 2022-11-04 23:18:48 +0100 | [diff] [blame] | 42 | |
| garciadeblas | 9f58633 | 2022-11-28 23:54:26 +0100 | [diff] [blame^] | 43 | RUN pip3 install \ |
| 44 | -r /home/airflow/.local/lib/python3.8/site-packages/osm_common/requirements.txt \ |
| 45 | -r /home/airflow/.local/lib/python3.8/site-packages/osm_ngsa/requirements.txt |
| 46 | |