- Run
docker build . -t dssat-csm
- See the available tags (you can use any git commit, tag, etc for this)
- Pass the desired tag as
DSSAT_GIT_TAG
:docker build . -t dssat-csm --build-arg DSSAT_GIT_TAG=v4.8.0.27
(replace the tag with the desired one)
Note: you can combine both DSSAT_GIT_TAG
and DSSAT_GIT_REPO arguments
- Pass the desired repo URL as
DSSAT_GIT_REPO
:docker build . -t dssat-csm --build-arg DSSAT_GIT_REPO=https://github.com/NathanPB/dssat-csm-os.git
(replace the URL with the desired one)
Note: you can combine both DSSAT_GIT_TAG and DSSAT_GIT_REPO
arguments
Due Docker security measures you need to paste your source files into the ./src
directory, and then use the local.Dockerfile
file to build from:
- Run
docker build . -f local.Dockerfile -t dssat
If you followed the above steps your image should be tagged as dssat-csm
(feel free to change this tag label).
- Change to the directory with your experimental files (XFile, etc.)
- Run the container:
docker run --rm -v ${PWD}:/data -w /data dssat-csm A <xfile name>
ordocker run --rm -v ${PWD}:/data -w /data dssat-csm B <batch file name>