Skip to content

Latest commit

 

History

History
83 lines (55 loc) · 1.67 KB

README.md

File metadata and controls

83 lines (55 loc) · 1.67 KB

Site configuration for AWS Amazon Linux

Bootstrapping

The environments have a number of dependencies that are required for Conda and Spack to work. These can be installed with the included bootstrap.sh script.

You will need to manually install git with sudo dnf install git to check out this repository.

If conda and spack are not already installed you can install them and their dependencies with

# Configure where environments are installed
export NGMOENVS_BASEDIR=~/ngmo-envs

./site/aws/bootstrap.sh

This will print out the path to an activate script which you should source before installing or using environments, e.g.

source ~/ngmo-envs/bin/activate

SVN Credentials

Store SVN credentials in GPG agent by running

conda env create -n svn subversion
conda activate svn

sudo dnf install pinentry-tty

mkdir -p ~/.gnupg
echo "pinentry-program /usr/bin/pinentry-tty" >> ~/.gnupg/gpg-agent.conf

gpg-connect-agent reloadagent /bye

export GPG_TTY=$(tty)

cat >> ~/.subversion/config <<EOF
[auth]
store-passwords = yes
EOF

svn info https://code.metoffice.gov.uk/svn/lfric

Installing Environments

Install an environment from the environments/ directory with

source ~/ngmo-envs/bin/activate

# Configure the compiler and MPI to use
export NGMOENVS_COMPILER=gcc
export NGMOENVS_MPI=openmpi@4

# The environment to install
export ENV=lfric

./site/aws/install.sh $ENV

Using environments

Make sure the environment's bin/ directory is on your PATH:

export PATH=${NGMOENVS_BASEDIR}/envs/lfric/bin:$PATH

Run commands inside the environment using the envrun script.

envrun make
envrun mpirun -n 6 lfric