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

Dockerfile overhaul #1357

Merged
merged 2 commits into from
Aug 28, 2023
Merged

Conversation

madsboddum
Copy link
Member

@madsboddum madsboddum commented Aug 18, 2023

Fixes #1351

In short:

  • CI/CD pipeline now attempts to build the docker image, so we can have more confidence that it's actually working
  • Running jlink now happens inside the docker image build, so it's portable
  • Final Docker image size has been reduced by ~30% (240MB -> 170MB)

Dependabot

As for automatic updates to the base image using Dependabot, being a multi-stage build now, we appear to have lost the option to have Dependabot submit update PRs: dependabot/dependabot-core#7640
Technically we could work around it by having two Dockerfiles, as described in that issue, but I'm unsure if the added complexity is worth it at this time.

Docker image size

Debian Stretch has been replaced with Alpine 3.
Docker image size difference, Alpine vs. Debian:

Screenshot from 2023-08-18 23-52-26

…he Docker image works on any host OS

Problem was that jlink produces OS-specific artifacts, so you couldn't make a functional Docker image on Windows.
Final Docker image size has also been reduced, roughly from 240MB to 170MB, by using Alpine as the new base image.
Support for Debian Stretch ended on the 30th of June 2022.
@madsboddum madsboddum marked this pull request as ready for review August 19, 2023 00:09
@madsboddum madsboddum changed the title Dockerfile overhaul and automatic updates Dockerfile overhaul Aug 19, 2023
@Josh-Larson Josh-Larson merged commit bee4d25 into ProjectSWGCore:master Aug 28, 2023
2 checks passed
@madsboddum madsboddum deleted the docker-base-image branch August 28, 2023 04:27
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.

[Misc] Update base Docker image and lock version
2 participants