Skip to content

Commit

Permalink
[8.17] includes liberation fonts in dockerfile (elastic#204368) (elas…
Browse files Browse the repository at this point in the history
…tic#204698)

# Backport

This will backport the following commits from `main` to `8.17`:
- [includes liberation fonts in dockerfile
(elastic#204368)](elastic#204368)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Eyo O.
Eyo","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-12-18T09:12:12Z","message":"includes
liberation fonts in dockerfile (elastic#204368)\n\n## Summary\r\n\r\nThis PR
includes liberations fonts in the docker file for Kibana.
\r\n\r\ninformed by elastic/sdh-kibana#5097,
we\r\npreviously used to package liberation fonts within Dockerfile but
this\r\nwas removed in elastic#183334,
it's\r\nhowever required for reporting on linux especially that these
fonts\r\naren't provided by default, resulting in not so optimal
rendering of\r\nusers reports.\r\n\r\n<!--\r\n### Checklist\r\n\r\nCheck
the PR satisfies following conditions. \r\n\r\nReviewers should verify
this PR satisfies this list as well.\r\n\r\n- [ ] Any text added follows
[EUI's
writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing),
uses\r\nsentence case text and includes
[i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n-
[
]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas
added for features that require explanation or tutorials\r\n- [ ] [Unit
or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n- [ ] If a plugin
configuration key changed, check if it needs to be\r\nallowlisted in the
cloud and added to the
[docker\r\nlist](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)\r\n-
[ ] This was checked for breaking HTTP API changes, and any
breaking\r\nchanges have been approved by the breaking-change committee.
The\r\n`release_note:breaking` label should be applied in these
situations.\r\n- [ ] [Flaky
Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1)
was\r\nused on any tests changed\r\n- [ ] The PR description includes
the appropriate Release Notes section,\r\nand the correct
`release_note:*` label is applied per
the\r\n[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\r\n\r\n###
Identify risks\r\n\r\nDoes this PR introduce any risks? For example,
consider risks like hard\r\nto test bugs, performance regression,
potential of data loss.\r\n\r\nDescribe the risk, its severity, and
mitigation for each identified\r\nrisk. Invite stakeholders and evaluate
how to proceed before merging.\r\n\r\n- [ ] [See some
risk\r\nexamples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)\r\n-
[ ] ...\r\n\r\n\r\n-->\r\n\r\nCo-authored-by: Elastic Machine
<[email protected]>","sha":"87440cf335e59032c05c883d467d01a367aaa0cf","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","backport:prev-major","ci:cloud-deploy","ci:build-serverless-image","ci:build-docker-fips","Feature:Reporting:Framework"],"title":"includes
liberation fonts in
dockerfile","number":204368,"url":"https://github.com/elastic/kibana/pull/204368","mergeCommit":{"message":"includes
liberation fonts in dockerfile (elastic#204368)\n\n## Summary\r\n\r\nThis PR
includes liberations fonts in the docker file for Kibana.
\r\n\r\ninformed by elastic/sdh-kibana#5097,
we\r\npreviously used to package liberation fonts within Dockerfile but
this\r\nwas removed in elastic#183334,
it's\r\nhowever required for reporting on linux especially that these
fonts\r\naren't provided by default, resulting in not so optimal
rendering of\r\nusers reports.\r\n\r\n<!--\r\n### Checklist\r\n\r\nCheck
the PR satisfies following conditions. \r\n\r\nReviewers should verify
this PR satisfies this list as well.\r\n\r\n- [ ] Any text added follows
[EUI's
writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing),
uses\r\nsentence case text and includes
[i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n-
[
]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas
added for features that require explanation or tutorials\r\n- [ ] [Unit
or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n- [ ] If a plugin
configuration key changed, check if it needs to be\r\nallowlisted in the
cloud and added to the
[docker\r\nlist](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)\r\n-
[ ] This was checked for breaking HTTP API changes, and any
breaking\r\nchanges have been approved by the breaking-change committee.
The\r\n`release_note:breaking` label should be applied in these
situations.\r\n- [ ] [Flaky
Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1)
was\r\nused on any tests changed\r\n- [ ] The PR description includes
the appropriate Release Notes section,\r\nand the correct
`release_note:*` label is applied per
the\r\n[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\r\n\r\n###
Identify risks\r\n\r\nDoes this PR introduce any risks? For example,
consider risks like hard\r\nto test bugs, performance regression,
potential of data loss.\r\n\r\nDescribe the risk, its severity, and
mitigation for each identified\r\nrisk. Invite stakeholders and evaluate
how to proceed before merging.\r\n\r\n- [ ] [See some
risk\r\nexamples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)\r\n-
[ ] ...\r\n\r\n\r\n-->\r\n\r\nCo-authored-by: Elastic Machine
<[email protected]>","sha":"87440cf335e59032c05c883d467d01a367aaa0cf"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/204368","number":204368,"mergeCommit":{"message":"includes
liberation fonts in dockerfile (elastic#204368)\n\n## Summary\r\n\r\nThis PR
includes liberations fonts in the docker file for Kibana.
\r\n\r\ninformed by elastic/sdh-kibana#5097,
we\r\npreviously used to package liberation fonts within Dockerfile but
this\r\nwas removed in elastic#183334,
it's\r\nhowever required for reporting on linux especially that these
fonts\r\naren't provided by default, resulting in not so optimal
rendering of\r\nusers reports.\r\n\r\n<!--\r\n### Checklist\r\n\r\nCheck
the PR satisfies following conditions. \r\n\r\nReviewers should verify
this PR satisfies this list as well.\r\n\r\n- [ ] Any text added follows
[EUI's
writing\r\nguidelines](https://elastic.github.io/eui/#/guidelines/writing),
uses\r\nsentence case text and includes
[i18n\r\nsupport](https://github.com/elastic/kibana/blob/main/packages/kbn-i18n/README.md)\r\n-
[
]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas
added for features that require explanation or tutorials\r\n- [ ] [Unit
or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common scenarios\r\n- [ ] If a plugin
configuration key changed, check if it needs to be\r\nallowlisted in the
cloud and added to the
[docker\r\nlist](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)\r\n-
[ ] This was checked for breaking HTTP API changes, and any
breaking\r\nchanges have been approved by the breaking-change committee.
The\r\n`release_note:breaking` label should be applied in these
situations.\r\n- [ ] [Flaky
Test\r\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1)
was\r\nused on any tests changed\r\n- [ ] The PR description includes
the appropriate Release Notes section,\r\nand the correct
`release_note:*` label is applied per
the\r\n[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\r\n\r\n###
Identify risks\r\n\r\nDoes this PR introduce any risks? For example,
consider risks like hard\r\nto test bugs, performance regression,
potential of data loss.\r\n\r\nDescribe the risk, its severity, and
mitigation for each identified\r\nrisk. Invite stakeholders and evaluate
how to proceed before merging.\r\n\r\n- [ ] [See some
risk\r\nexamples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)\r\n-
[ ] ...\r\n\r\n\r\n-->\r\n\r\nCo-authored-by: Elastic Machine
<[email protected]>","sha":"87440cf335e59032c05c883d467d01a367aaa0cf"}}]}]
BACKPORT-->

Co-authored-by: Eyo O. Eyo <[email protected]>
  • Loading branch information
kibanamachine and eokoneyo authored Dec 18, 2024
1 parent 03823ec commit 6244060
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ EXPOSE 5601
RUN for iter in {1..10}; do \
microdnf update --setopt=tsflags=nodocs -y && \
microdnf install --setopt=tsflags=nodocs -y \
fontconfig freetype shadow-utils nss findutils && \
fontconfig liberation-fonts-common freetype shadow-utils nss findutils && \
microdnf clean all && exit_code=0 && break || exit_code=$? && echo "microdnf error: retry $iter in 10s" && \
sleep 10; \
done; \
Expand All @@ -126,15 +126,15 @@ RUN for iter in {1..10}; do \
apt-get update && \
apt-get upgrade -y && \
apt-get install -y --no-install-recommends \
fontconfig libnss3 curl ca-certificates && \
fontconfig fonts-liberation libnss3 curl ca-certificates && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* && exit_code=0 && break || exit_code=$? && echo "apt-get error: retry $iter in 10s" && \
sleep 10; \
done; \
(exit $exit_code)
{{/ubuntu}}
{{#wolfi}}
RUN apk --no-cache add bash curl fontconfig libstdc++ libnss findutils shadow ca-certificates
RUN apk --no-cache add bash curl fontconfig font-liberation libstdc++ libnss findutils shadow ca-certificates
{{/wolfi}}

# Bring in Kibana from the initial stage.
Expand Down

0 comments on commit 6244060

Please sign in to comment.