Conda MOOSE Environment
Our preferred method for obtaining dependencies necessary for MOOSE-based application development is via Conda's myriad array of libraries. Follow these instructions to create an environment on your machine using Conda. At this time, an option to install MOOSE directly on a Windows system is not yet supported. On-going efforts are being made to add a conda installation option for Windows, and an experimental WSL option is available.
Install Mambaforge3
Follow the steps below depending on your platform to install mambaforge. If you run into issues during these steps, please visit our troubleshooting guide for Conda. This installation guide relies on the utilization of mamba
, an optimized package manager for Conda.
Linux Users:
curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh bash Mambaforge-Linux-x86_64.sh -b -p ~/mambaforge3
Macintosh Users with Intel processors:
curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-MacOSX-x86_64.sh bash Mambaforge-MacOSX-x86_64.sh -b -p ~/mambaforge3
With Mambaforge installed to your home directory, export PATH, so that it may be used:
export PATH=$HOME/mambaforge3/bin:$PATH
Configure Conda to work with our INL public channel:
conda config --add channels https://conda.software.inl.gov/public
If you find yourself using sudo conda
/sudo mamba
... something is not right. The most common reason for needing sudo is due to an improper Conda installation. Conda should be installed to your home directory, without any use of sudo
.
Install MOOSE Conda Packages
Before we create our virtual conda environment, we first need to initialize mamba. For this, execute the following command and restart your terminal session.
mamba init
Next, create a unique conda environment for moose, named moose
, and attempt to activate it:
mamba create --name moose -q -y
mamba activate moose
Within the moose
environment, install the necessary packages:
mamba install moose-tools moose-libmesh
Once the packages are installed, the moose
environment needs to be deactivated and reactivated to ensure that the environmental variables in the installed packages are set properly.
mamba deactivate
mamba activate moose
If you are running into errors, please see our troubleshooting guide for Conda.
Know that you will need to mamba activate moose
again for each terminal window you open. If you wish to make this automatic, you can add that command to the end of your shell profile.
Cloning MOOSE
MOOSE is hosted on GitHub and should be cloned directly from there using git. We recommend creating a directory named projects to put all of your MOOSE related work.
To install MOOSE run the following commands in a terminal.
mkdir ~/projects
cd ~/projects
git clone https://github.com/idaholab/moose.git
cd moose
git checkout master
The master branch of MOOSE is the stable branch that will only be updated after all tests are passing. This protects you from the day-to-day changes in the MOOSE repository.
Compile and Test MOOSE
cd ~/projects/moose/test
make -j 4
./run_tests -j 4
If the installation was successful you should see most of the tests passing (some tests will be skipped depending on your system environment).
Head back over to the Install MOOSE page to continue your tour of MOOSE.
Uninstall Conda MOOSE Environment
If you wish to remove the moose environment at any time, you may do so using the following commands:
conda deactivate # if 'moose' was currently activated
conda remove --name moose --all