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 make docker-build in Integration Testing #93

Closed
kr11 opened this issue Aug 26, 2024 · 5 comments
Closed

Add make docker-build in Integration Testing #93

kr11 opened this issue Aug 26, 2024 · 5 comments
Assignees
Labels
area/cicd area/testing Issues or PRs related to testing
Milestone

Comments

@kr11
Copy link
Collaborator

kr11 commented Aug 26, 2024

Summary

This issue proposes the addition of integration tests for the make docker-build command to enhance reliability and detect configuration errors early in the development cycle.

Motivation

Currently, our typical debugging processes involve using make run or debugging via GoLand. However, these methods have significant limitations:

  1. RBAC Exposure Issue: The make run command does not reveal issues related to Role-Based Access Control (RBAC). For example, a previous PR addressed this error about horizontalpodautoscalers (PR #72). A similar bug will be addressed in the upcoming PR for podautoscaler_controller - KPA.

  2. Detection of Specific Build Issues: Certain problems, such as missing packages or inconsistencies between go.mod and the Dockerfile versions, only become apparent when running make docker-build. An example of this was seen in Pull #92.

These challenges underscore the need for a more robust testing process that can preemptively identify and address potential issues before deployment.

Proposed Change

Some potential ways to solve it include:

  • Automated Test Suite: Develop a suite of automated tests that are triggered by changes in the Dockerfile or associated configuration files.
  • Continuous Integration Setup: Configure the CI pipeline to execute make docker-build and run tests on every push or pull request to the main branch.

Alternatives Considered

No response

@kr11 kr11 added area/testing Issues or PRs related to testing area/cicd labels Aug 26, 2024
@kr11
Copy link
Collaborator Author

kr11 commented Aug 26, 2024

@Jeffwan

@Jeffwan
Copy link
Collaborator

Jeffwan commented Aug 26, 2024

@kr11 Let's use [Feat] or something else instead. Let's reserve RFC for some component or architecture changes

@Jeffwan
Copy link
Collaborator

Jeffwan commented Aug 29, 2024

This is great suggestion. make docker-build will be included in the CI after #30. make run does have some assumptions. For debugging purpose, I suggest to improve the development documentation if there's additional check we can do. At the same time, we can also do some local integration tests which means running them in local Kubernetes which may help find the issue earlier.

@Jeffwan Jeffwan changed the title [RFC]: Add Integration Testing for make docker-build Add make docker-build in Integration Testing Aug 29, 2024
@Jeffwan Jeffwan added this to the v0.1.0-rc.1 milestone Aug 29, 2024
@Jeffwan Jeffwan self-assigned this Sep 4, 2024
@Jeffwan
Copy link
Collaborator

Jeffwan commented Sep 4, 2024

@kr11 docker-build has been added in the PR pipeline here #120 . However, the RBAC can not be tested in this CI yet. I create a new issue #121 to test yaml setup as part of the aibrix integration pipeline.

@Jeffwan
Copy link
Collaborator

Jeffwan commented Sep 5, 2024

#120 has been merged and a corresponding fix has been proposed #127. This can be closed now. Feel free to reopen if you think there're unfinished items. @kr11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/cicd area/testing Issues or PRs related to testing
Projects
None yet
Development

No branches or pull requests

3 participants