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

add distroless otel init #10035

Merged
merged 1 commit into from
Jun 12, 2023
Merged

Conversation

esigo
Copy link
Member

@esigo esigo commented Jun 3, 2023

What this PR does / why we need it:

This PR makes the following changes to improve the init container in the project:

  • Switches the init container image to a distroless image, reducing the image size from 20MB to 18MB. This helps to optimize the image and reduce its footprint.
  • Introduces the use of Ninja build system for faster builds, improving the build performance of the init container.
    The transition to a distroless image enhances the security of the init container by minimizing the attack surface and reducing the number of unnecessary components.
    These changes aim to enhance the efficiency, security, and overall performance of the init container.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • CVE Report (Scanner found CVE and adding report)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation only

Which issue/s this PR fixes

No specific issue is fixed by this PR.

How Has This Been Tested?

The init container with the distroless image has been built and deployed in a test environment.
Verification of successful pod initialization and functionality of the init container.
Manual testing to ensure that the overall build performance and image size reduction have been achieved.
Existing unit and integration tests have been executed to validate the changes.

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I've read the CONTRIBUTION guide.
  • I have added unit and/or e2e tests to cover my changes.
  • All new and existing tests passed.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Jun 3, 2023
@k8s-ci-robot
Copy link
Contributor

This issue is currently awaiting triage.

If Ingress contributors determines this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the needs-kind Indicates a PR lacks a `kind/foo` label and requires one. label Jun 3, 2023
@k8s-ci-robot k8s-ci-robot requested a review from cpanato June 3, 2023 18:44
@k8s-ci-robot k8s-ci-robot added area/helm Issues or PRs related to helm charts size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Jun 3, 2023
add distroless otel init

func main() {
// Enable error handling for all operations
err := run()
Copy link
Contributor

Choose a reason for hiding this comment

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

super nit:

I would do an if err := run(); err != nil

@rikatz
Copy link
Contributor

rikatz commented Jun 11, 2023

/lgtm
/approve
/hold
Left a minor nit, but you can ignore it for now :)

@k8s-ci-robot k8s-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 11, 2023
@k8s-ci-robot k8s-ci-robot added lgtm "Looks good to me", indicates that a PR is ready to be merged. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jun 11, 2023
Copy link
Member

@cpanato cpanato left a comment

Choose a reason for hiding this comment

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

/lgtm

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cpanato, esigo, rikatz

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@rikatz
Copy link
Contributor

rikatz commented Jun 12, 2023

/hold cancel

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 12, 2023
@k8s-ci-robot k8s-ci-robot merged commit 436df32 into kubernetes:main Jun 12, 2023
32 checks passed
@esigo esigo deleted the distroless-otel branch July 29, 2023 17:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/helm Issues or PRs related to helm charts cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-kind Indicates a PR lacks a `kind/foo` label and requires one. needs-priority needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants