0

I've been deploying a Node JS project that runs a Python script on Azure web app on Linux.

I've installed Conda in my /home/miniconda3 directory, but when I run the app it does recognizes neither the path nor the packages installed, like pandas or other. However, the installation is clearly present:

Conda files exist !!

How can I make persistent the Conda installation?

merv
  • 67,214
  • 13
  • 180
  • 245
  • You can refer to [How to change default Anaconda python environment](https://stackoverflow.com/questions/28436769/how-to-change-default-anaconda-python-environment) and [Conda (+ pip) and Docker FTW!](https://towardsdatascience.com/conda-pip-and-docker-ftw-d64fe638dc45) – Ecstasy Dec 07 '21 at 06:01

1 Answers1

0

Make sure you update the conda and install python:

conda update conda
conda install python=3.X

You can follow the below steps to activate the environment with few commands:

source activate environment-name
source conda activate environment-name

Below commands helped me in building conda environment:

#build the conda environment  
ENV ENV_PREFIX $PWD/env  
RUN conda update --name base --channel defaults conda && \  
    conda env create --prefix $ENV_PREFIX --file /tmp/environment.yml --force && \  
    conda clean --all --yes# run the postBuild script to install any JupyterLab extensions  
RUN conda activate $ENV_PREFIX && \  
    /usr/local/bin/postBuild.sh && \  
    conda deactivate

You can have a look on the links mentioned by DeepDave.

SaiKarri-MT
  • 1,174
  • 1
  • 3
  • 8