diff --git a/docs/getting_started/index.md b/docs/getting_started/index.md index 21ed1d6e3..faf2db41b 100644 --- a/docs/getting_started/index.md +++ b/docs/getting_started/index.md @@ -28,9 +28,9 @@ spack
- Set up Spack for model builds + Set up Spack for building ACCESS models - Spack is a flexible package manager used to build ACCESS models. + Spack is a build-from-source package manager that is used to build ACCESS models.
diff --git a/docs/getting_started/spack.md b/docs/getting_started/spack.md index 58fc73bcb..6cac0baef 100644 --- a/docs/getting_started/spack.md +++ b/docs/getting_started/spack.md @@ -1,10 +1,15 @@ -# Set up Spack for model builds +[spack_environments]: https://spack.readthedocs.io/en/latest/environments.html + +# Set up Spack for building ACCESS models [Spack](https://spack.io/about/) is a build-from-source package manager, specifically designed to simplify the installation of scientific software on supercomputers. +To know more about _Spack_ usage, please familiarise yourself with the [Basic Usage instructions](https://spack.readthedocs.io/en/latest/basic_usage.html) and [Environments][spack_environments].
+We also reccommend that you refer to the [Spack 101 Tutorial](https://spack-tutorial.readthedocs.io/en/latest/). + + ## Prerequisites -To use _Spack_ on _Gadi_, you must have an NCI account.
-For instructions on how to set up an account, refer to [Set Up your NCI Account](/getting_started/set_up_nci_account). +These instructions are tailored specifically for _Gadi_. To use _Spack_ on _Gadi_, you must have an NCI account. For instructions on how to set up an account, refer to [Set Up your NCI Account](/getting_started/set_up_nci_account). ## Set up Spack on Gadi @@ -13,7 +18,7 @@ For instructions on how to set up an account, refer to [Set Up your NCI Account] !!! tip This step is optional, but it is recommended you have a selected directory where to keep your _Spack_ distribution. -The complete _Spack_ distribution is approximately 120 MB in size. For this reason, we reccommend placing its directory somewhere in `/g/data`. An example can be `/g/data/$PROJECT/$USER/spack_distribution`. +The complete _Spack_ distribution is approximately 120 MB in size, with additional space needed for all the packages built. For this reason, we reccommend placing its directory somewhere in `/g/data/`. An example can be `/g/data/$PROJECT/$USER/spack_distribution`. To create the directory mentioned above and navigate into it, run the following command: ``` @@ -41,15 +46,15 @@ ln -s -r -v spack-config/v0.22/gadi/* spack/etc/spack/ !!! success Your _Spack_ setup is complete! -### Test Spack +## Test Spack (OPTIONAL) -To test _Spack_ we will create an environment (in this example it will be the on to build ACCESS-OM2 executables) and build the relevant packages. Then, we will uninstall all the packages and remove the environment. +To test _Spack_ we will create an [environment][spack_environments] (in this example it will be the one used to build [ACCESS-OM2](/models/configurations/access-om#access-om2) executables) and build the relevant packages. Then, we will uninstall all the packages and remove the environment. All the steps listed above can be performed by running the following commands (where `` is the [directory for the Spack distribution](#create-a-directory-for-the-spack-distribution)): ``` . /spack-config/spack-enable.bash -curl -L https://raw.githubusercontent.com/ACCESS-NRI/ACCESS-OM2/main/spack.yaml -o access-om2-spack.yaml -spack env create access-om2 access-om2-spack.yaml +git clone https://github.com/ACCESS-NRI/ACCESS-OM2.git +spack env create access-om2 ACCESS-OM2/spack.yaml spack env activate -p access-om2 spack find spack install --verbose @@ -57,9 +62,5 @@ spack find spack uninstall --remove --all -y spack env deactivate spack env rm access-om2 -y -rm access-om2-spack.yaml +rm -rf ACCESS-OM2 ``` - -### More information -To know more about _Spack_ usage, please familiarise yourself with the [Basic Usage instructions](https://spack.readthedocs.io/en/latest/basic_usage.html) and [Environments](https://spack.readthedocs.io/en/latest/environments.html).
-We also reccommend you check the [Spack 101 Tutorial](https://spack-tutorial.readthedocs.io/en/latest/). \ No newline at end of file diff --git a/mkdocs.yml b/mkdocs.yml index ecdd3bcdb..a59e30adf 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -99,7 +99,7 @@ nav: - getting_started/index.md - Set Up your NCI Account: getting_started/set_up_nci_account.md - Australian Research Environment (ARE): getting_started/are.md - - Set up spack for model builds: getting_started/spack.md + - Set up Spack for building ACCESS models: getting_started/spack.md - Models: - Models: models/index.md