Make swagger download automatically select architecture
Comprehensive Summary of your change
This does not work for all architectures, but at least amd64 and arm64. I could also add a switch statement, but ARM64 seems to be the most important arch to implement right now (#3505).
Issue being fixed
Helps towards #3505
Please indicate you've done the following:
- [x] Well Written Title and Summary of the PR
- [x] Label the PR as needed. "release-note/ignore-for-release, release-note/new-feature, release-note/update, release-note/enhancement, release-note/community, release-note/breaking-change, release-note/docs, release-note/infra, release-note/deprecation"
- [x] Accepted the DCO. Commits without the DCO will delay acceptance.
- [x] Made sure tests are passing and test coverage is added if needed.
- [x] Considered the docs impact and opened a new docs issue or PR with docs changes if needed in website repository.
this command dpkg --print-architecture doesn't work in MacOSX
Could you please contribute in the following repo to support Harbor in ARM:
- https://github.com/goharbor/harbor-arm
Thanks
this command
dpkg --print-architecturedoesn't work in MacOSX
The container is always a Linux container, isn't it?
And https://github.com/goharbor/harbor-arm seems unmaintained.
In my opinion, a second repo for arm is unnecessary considering how small the changes for arm64 support would need to be (This PR + another 10 line patch).
So please reopen or reconsider this PR.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 66.43%. Comparing base (
b7b8847) to head (98ff607). Report is 376 commits behind head on main.
Additional details and impacted files
@@ Coverage Diff @@
## main #19780 +/- ##
==========================================
- Coverage 67.56% 66.43% -1.14%
==========================================
Files 991 1048 +57
Lines 109181 116119 +6938
Branches 2719 2845 +126
==========================================
+ Hits 73768 77142 +3374
- Misses 31449 34595 +3146
- Partials 3964 4382 +418
| Flag | Coverage Δ | |
|---|---|---|
| unittests | 66.43% <ø> (-1.14%) |
:arrow_down: |
Flags with carried forward coverage won't be shown. Click here to find out more.
This PR is being marked stale due to a period of inactivty. If this PR is still relevant, please comment or remove the stale label. Otherwise, this PR will close in 30 days.
This PR is being marked stale due to a period of inactivty. If this PR is still relevant, please comment or remove the stale label. Otherwise, this PR will close in 30 days.
@Vad1mo Any news on this?
this command
dpkg --print-architecturedoesn't work in MacOSX
It is not intended to work on Mac, the command is executed in the container and guaranteed to be there. The only thing it does is selection the right CPU architecture. which in terms allows you to build images on your ARM pc/mac
I think it solves a problem and does not impact the current image build in any way.
This PR is being marked stale due to a period of inactivty. If this PR is still relevant, please comment or remove the stale label. Otherwise, this PR will close in 30 days.
This PR was closed because it has been stalled for 30 days with no activity. If this PR is still relevant, please re-open a new PR against main.
This PR is being marked stale due to a period of inactivty. If this PR is still relevant, please comment or remove the stale label. Otherwise, this PR will close in 30 days.
This PR is being marked stale due to a period of inactivty. If this PR is still relevant, please comment or remove the stale label. Otherwise, this PR will close in 30 days.
This PR was closed because it has been stalled for 30 days with no activity. If this PR is still relevant, please re-open a new PR against main.
@Vad1mo that's quite outdated check here: https://github.com/goharbor/harbor/commit/b0545c05fd0a70c589f21cdce0bf4e0e60842ed8
right we do now RUN go install github.com/go-swagger/go-swagger/cmd/swagger@$SWAGGER_VERSION
didn't see that, we can close it as resolved than.