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

feat(docker): allow for docker release builds to be multi-platform #27055

Merged
merged 13 commits into from
Feb 9, 2024

Conversation

mistercrunch
Copy link
Member

@mistercrunch mistercrunch commented Feb 8, 2024

SUMMARY

Allow for release builds to be multi-platform

This PR:

  • adds support for multi-platform builds to the scripts/build_docker.py CLI
  • changes the GitHub Action .github/workflows/docker-release.yml to
    build multi-platform images that can be used in helm or docker-compose

closes #27043

Testing / validation

Testing using the workflow_dispatch here -> https://github.com/apache/superset/actions/runs/7835882887/job/21382286370

Validated the images look ok on Docker hub ->
Screenshot 2024-02-08 at 1 06 54 PM

Copy link

codecov bot commented Feb 8, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (ee69ac9) 67.19% compared to head (0655ac2) 67.19%.
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #27055   +/-   ##
=======================================
  Coverage   67.19%   67.19%           
=======================================
  Files        1899     1899           
  Lines       74380    74380           
  Branches     8275     8275           
=======================================
+ Hits        49981    49982    +1     
+ Misses      22344    22343    -1     
  Partials     2055     2055           
Flag Coverage Δ
mysql 77.98% <ø> (-0.03%) ⬇️
postgres 78.11% <ø> (ø)
python 78.25% <ø> (+<0.01%) ⬆️
sqlite 77.62% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mistercrunch mistercrunch force-pushed the docker_multi_platform_releases branch from 68cf9b0 to 71fd8c3 Compare February 9, 2024 03:14
@mistercrunch mistercrunch merged commit 13915bb into master Feb 9, 2024
37 checks passed
@mistercrunch mistercrunch deleted the docker_multi_platform_releases branch February 9, 2024 04:58
@merlos
Copy link

merlos commented Feb 9, 2024

@mistercrunch 👏🏻👏🏻👏🏻👏🏻👏🏻

mistercrunch added a commit that referenced this pull request Feb 12, 2024
In #27055, I broke the master
builds while making the `run_cmd` method raise if it gets a non-zero exit
status. Turned out to only fail while in the `pull_request` context.

This is the change: https://github.com/apache/superset/pull/27055/files#diff-3cf86f687684a2c690521532de75a831def641338f5a9ec1da8add94714def4cR44-R45

This is the observed error in master build

```
Traceback (most recent call last):
 {...REDACTED...}
  File "/home/runner/work/superset/superset/./scripts/build_docker.py", line 76, in is_latest_release
    output = run_cmd(f"./scripts/tag_latest_release.sh {release} --dry-run") or ""
  File "/home/runner/work/superset/superset/./scripts/build_docker.py", line 45, in run_cmd
    raise subprocess.CalledProcessError(process.returncode, command, output)
subprocess.CalledProcessError: Command './scripts/tag_latest_release.sh master --dry-run' returned non-zero exit status 1.
Error: Process completed with exit code 1.
```

This disregards the exit code the `tag_latest_release.sh` since it seems
to be return error codes in expected situations.
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 4.0.0 labels Apr 17, 2024
vinothkumar66 pushed a commit to vinothkumar66/superset that referenced this pull request Nov 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels github_actions Pull requests that update GitHub Actions code size/L 🚢 4.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants