Goddard-Fortran-Ecosystem / gFTL

Software containers for Fortran
Apache License 2.0
43 stars 10 forks source link

How do we build GFTL on an airgapped system #209

Open GeorgeVandenberghe-NOAA opened 11 months ago

GeorgeVandenberghe-NOAA commented 11 months ago

The GFTL repository itself can be copied to an airgapped system with .. on connected system

git clone https://github.com/Goddard-Fortran-Ecosystem/gFTL-shared

then copy the gFTL-shared directory to the airgapped system and attempt further build. Upon doing so ON THE AIRGAPPED SYSTEM though the build generates

cd gFTL-shared/

How do we do this build on an airgapped system (NOAA jet tjet node in this example)?

tclune commented 9 months ago

So sorry - this issue apparently got buried during my winter vacation ...

This has come up before with a Cray system. The intent was that CMake should only reach outside if it cannot find the submodules, but the existing logic fails there. Adding in @mathomp4 so we can discusse.

Quite likely not a single gFTL/GFE user is relying on this capability, but without being certain, I'm reluctant to delete it. OTOH, we should be able to create a nice message telling the person to get the submodules ...

mathomp4 commented 9 months ago

@GeorgeVandenberghe-NOAA I can think of a few things.

Previously built gFTL

If you've already installed gFTL somewhere, then you'd just need to add the path to CMAKE_PREFIX_PATH when you run CMake.

Starting with gFTL-shared

If you are starting with gFTL-shared, then you'd want to git clone --recurse-submodules at which point I believe it wouldn't have a need to go out. For example, on a discover login node (with internet access), I did:

git clone --recurse-submodules git@github.com:Goddard-Fortran-Ecosystem/gFTL-shared.git

and then on a compute node (no internet):

cmake -B build -S .
cmake --build build --target install

worked just fine so it didn't try and fetch it.

Using GFE

Finally, I mainly install GFE libraries via GFE itself which always presents a "consistent" set of versions. For that:

git clone git@github.com:Goddard-Fortran-Ecosystem/GFE.git
cd GFE
git submodule update --init

and then build as usual.

GeorgeVandenberghe-NOAA commented 9 months ago

Thanks. I will modify my builds to try that.

On Mon, Feb 12, 2024 at 9:58 AM Matthew Thompson @.***> wrote:

@GeorgeVandenberghe-NOAA https://github.com/GeorgeVandenberghe-NOAA I can think of a few things.

If you've already installed gFTL somewhere, then you'd just need to add the path to CMAKE_PREFIX_PATH when you run CMake.

If you are starting with gFTL-shared, then you'd want to git clone --recurse-submodules at which point I believe it wouldn't have a need to go out. For example, on a discover login node (with internet access), I did:

git clone --recurse-submodules @.***:Goddard-Fortran-Ecosystem/gFTL-shared.git

and then on a compute node (no internet):

cmake -B build -S . cmake --build build --target install

worked just fine so it didn't try and fetch it.

Finally, I mainly install GFE libraries via GFE itself https://github.com/Goddard-Fortran-Ecosystem/GFE which always presents a "consistent" set of versions. For that:

git clone @.***:Goddard-Fortran-Ecosystem/GFE.git cd GFE git submodule update --init

and then build as usual.

— Reply to this email directly, view it on GitHub https://github.com/Goddard-Fortran-Ecosystem/gFTL/issues/209#issuecomment-1938837253, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANDS4FW23HIHFZ6N427VUQLYTIUXNAVCNFSM6AAAAABA3URL6CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMZYHAZTOMRVGM . You are receiving this because you were mentioned.Message ID: @.***>

--

George W Vandenberghe

Lynker Technologies at NOAA/NWS/NCEP/EMC

5830 University Research Ct., Rm. 2141

College Park, MD 20740

@.***

301-683-3769(work) 3017751547(cell)