Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove installation of wgrib from geospatial builds from ubuntu:jammy based images #576

Merged
merged 4 commits into from
Dec 16, 2022

Conversation

rdenham
Copy link
Contributor

@rdenham rdenham commented Dec 10, 2022

Gdal handles grib2 files well so no longer seems to be a need to install the
wgrib utility, which
is used to read and write grib2 files.

@eitsupi eitsupi added rocker scripts Related to rocker scripts pre-built images Related to pre-built images labels Dec 11, 2022
@eitsupi eitsupi linked an issue Dec 11, 2022 that may be closed by this pull request
@cboettig
Copy link
Member

Thanks @rdenham , this is a good change and will reduce bloat.

@eitsupi I think you've already resolved the issue wit the one failing test (lsb_release for shiny) elsewhere and so this should be good to merge!

@eitsupi
Copy link
Member

eitsupi commented Dec 11, 2022

Yes, the test failure is nothing to do with this PR.

I am only wondering if removing this will not change the behavior on focal based images as well.

@cboettig
Copy link
Member

@eitsupi good call. For consistency I agree we should leave wgrib on the focal images to meet reproducibility expectations (though maybe we should have had a higher bar of criteria to add custom installs like this that don't go through apt or RSPM for that reason).

Do you have a preferred pattern for checking the release version in a shell script? I think looking at /etc/issue is reasonable (has the release number but not the codename, but I think avoids any additional dependency like lsb_release -c ...

@rdenham could you add a conditional instead of removing the wgrib install such that it only runs on 20.04? (Note that the latest release of this stack and going forward are now all on 22.04, so it's a good time to make a change like this).

@eitsupi
Copy link
Member

eitsupi commented Dec 11, 2022

Do you have a preferred pattern for checking the release version in a shell script? I think looking at /etc/issue is reasonable (has the release number but not the codename, but I think avoids any additional dependency like lsb_release -c ...

I recommend like this:

# shellcheck source=/dev/null
source /etc/os-release
if [ "${UBUNTU_CODENAME}" == "focal" ]; then
    /rocker_scripts/install_wgrib2.sh
fi

@rdenham
Copy link
Contributor Author

rdenham commented Dec 11, 2022

@rdenham could you add a conditional instead of removing the wgrib install such that it only runs on 20.04? (Note that the latest release of this stack and going forward are now all on 22.04, so it's a good time to make a change like this).

Sure. Do you think there is merit in also removing unnecessary files left over from the install as well, or just leave it as is given it will only affect older builds?

@rdenham
Copy link
Contributor Author

rdenham commented Dec 12, 2022

@rdenham could you add a conditional instead of removing the wgrib install such that it only runs on 20.04? (Note that the latest release of this stack and going forward are now all on 22.04, so it's a good time to make a change like this).

Sure. Do you think there is merit in also removing unnecessary files left over from the install as well, or just leave it as is given it will only affect older builds?

Just replying to myself, to get this over the line, I think we should just use the wgrib install script as is for the focal images, without further modification.

@eitsupi
Copy link
Member

eitsupi commented Dec 13, 2022

Do you think there is merit in also removing unnecessary files left over from the install as well, or just leave it as is given it will only affect older builds?

I think it would be great if you could add a process to delete unnecessary files.
The focal-based images will continue to be built.

@cboettig cboettig merged commit 883e277 into rocker-org:master Dec 16, 2022
@eitsupi eitsupi changed the title Remove installation of wgrib from geospatial builds Remove installation of wgrib from geospatial builds from ubuntu:jammy based images Dec 17, 2022
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pre-built images Related to pre-built images rocker scripts Related to rocker scripts
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clean up /opt directory in geospatial
4 participants