Hands-on!

After install docker, docker-compose, subversion, git and all other packages we need (check this tutorial):

# create this folder in your home folder, but you can put this everywhere
mkdir ~/ROMS
# access your ROMS folder
cd ~/ROMS

# to download ROMS source code replace joe_roms by your username
svn checkout --username joe_roms https://www.myroms.org/svn/src/trunk src_code

# clone docker-roms repository from github (Magnim, you don't need to to this step)
git clone https://github.com/CoastalHydrodynamicsLab/docker-roms.git

# start the container running (Magnim, you don't need to to this step)
cd docker-roms
sudo docker-compose -f docker-compose-personal.yml up -d
# José Roberto: use docker-compose-shelfwaves.yml if you are running on shelfwaves

# create your projects folder
cd ~/ROMS
mkdir -p projects/upwelling

To run the upwelling test case, we need four files that already came with the source code. In fact, there are several test cases, but the upwelling is simpler to run and test if everything is OK with your system.

I strongly recommend to do the following steps outside the ROMS container and the, with all set, we can access and run our application.

cd ~/ROMS
cp src_code/ROMS/External/roms_upwelling.in projects/upwelling
cp src_code/ROMS/External/varinfo.dat projects/upwelling
cp src_code/ROMS/Include/upwelling.h  projects/upwelling
cp src_code/ROMS/Bin/build_roms.sh  projects/upwelling

Editing build_roms.sh:

MY_ROOT_DIR=${HOME}/roms_src
MY_PROJECT_DIR=${PWD}
MY_ROMS_SRC=${MY_ROOT_DIR}
FORT=gfortran
#export           USE_MPI=on            # distributed-memory parallelism
#export        USE_MPIF90=on

export         USE_LARGE=on            # activate 64-bit compilation
export       USE_NETCDF4=on            # compile with NetCDF-4 library

Editing roms_upwelling.in: