Skip to content

Perl Image followups #2

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

Closed
wants to merge 6 commits into from

Conversation

zakame
Copy link
Contributor

@zakame zakame commented Jul 17, 2020

  • Add dzil image recipe (both as new base for the existing https://hub.docker.com/r/deriv/dzil image and as an example of how to use deriv/perl)
  • Don't be too eager to purge auto-removable packages lest CPAN dependencies break, and make aptfile skippable if not present

zakame added 4 commits July 17, 2020 14:31
This also serves as a very simple example of using our base perl image.
- Check aptfile for readability, not size, so it can be skipped if the
 file doesn't exist.

- Do not auto-remove removable packages; removing them doesn't affect
  the overall image size anyway, and some packages (like runtime libraries
  auto-installed by their -dev counterparts) can be inadventently
  removed and break CPAN modules.
This probably needs its own workflow later, but for now just do a quick
build and check using the dzil image.
This is important for cross-compile builds (e.g. amd64 to arm64) as
cpanm/perl won't handle signals without defining them in the code, cf
Perl/docker-perl#44.  Without this,
cross-compiles will appear to stall.
apt-get -y -q update \
&& apt-get -y -q --no-install-recommends install $(cat /app/aptfile); \
fi \
&& cpanm --notest --quiet --installdeps --with-recommends . \
&& /usr/bin/dumb-init -- cpanm --notest --quiet --installdeps --with-recommends . \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why specifically cpanm requiring this? If it's a problem there, it'd be a problem everywhere, even apt install tends to run Perl code.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure if its even a Perl-only problem, as the case for this stems from cpanm subprocs like make/gcc/cc1 becoming zombies for some reason (hinting that some sub-parent is not handling signals,) and furthermore it doesn't happen on all cpanm installs. I agree that this might be placed further up in this RUN for the best coverage.

@zakame zakame force-pushed the docker/perl-image-followups branch from 4751956 to b938d13 Compare August 5, 2020 08:41
Remove this regardless of DEBIAN_PROXY being set or not.
@tom-binary
Copy link
Contributor

Combined these changes with some other fixes in #3, so this can be closed. Thanks!

@tom-binary tom-binary closed this Aug 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants