docker – Conda package without python enviroment
I try to install a conda package into a docker image, but conda changes default python, that is needed, after instalation. How I can solve this problem?
Can I use conda to install a package not into env, but into default system?
Conda package: faiss
Docker image: apache/airflow
Now my Dockerfile looks like:
FROM apache/airflow:latest-python3.8
# conda
USER root
COPY --from=continuumio/miniconda3:4.12.0 /opt/conda /opt/conda
ENV PATH=$PATH:/opt/conda/bin
RUN conda config --set always_yes yes --set changeps1 no && \
conda install -c pytorch faiss-cpu
And it installes faiss, but not in default python, that is used by airflow.
Read more here: Source link