buzzfeed / sso

sso, aka S.S.Octopus, aka octoboi, is a single sign-on solution for securing internal services
MIT License
3.07k stars 187 forks source link

update the makefile to push multi-arch images #319

Open danbf opened 2 years ago

danbf commented 2 years ago

Problem

current sso images don't support arm64 architecture. that means we can't run them on AWS Graviton's or Apple M1's

Solution

build a multi-arch with linux/amd64,linux/arm64 platform support

Notes

based on https://www.docker.com/blog/multi-arch-images/ and https://www.docker.com/blog/multi-arch-build-what-about-circleci/ our upstream, golang:1.14 supports these architectures and more

codecov[bot] commented 2 years ago

Codecov Report

Merging #319 (a135d77) into main (a1b1b74) will increase coverage by 0.22%. The diff coverage is n/a.

:exclamation: Current head a135d77 differs from pull request most recent head 171ce40. Consider uploading reports for the commit 171ce40 to get more accurate results Impacted file tree graph

@@            Coverage Diff             @@
##             main     #319      +/-   ##
==========================================
+ Coverage   62.73%   62.96%   +0.22%     
==========================================
  Files          58       58              
  Lines        4286     4760     +474     
==========================================
+ Hits         2689     2997     +308     
- Misses       1382     1546     +164     
- Partials      215      217       +2     
Impacted Files Coverage Δ
internal/auth/providers/group_cache.go 57.14% <0.00%> (-11.28%) :arrow_down:
internal/auth/logging_handler.go 28.12% <0.00%> (-2.07%) :arrow_down:
internal/proxy/logging_handler.go 14.75% <0.00%> (-1.58%) :arrow_down:
internal/pkg/httpserver/httpserver.go 66.66% <0.00%> (-1.20%) :arrow_down:
internal/auth/providers/google.go 58.49% <0.00%> (-0.66%) :arrow_down:
internal/auth/error.go 72.22% <0.00%> (-0.51%) :arrow_down:
internal/auth/mux.go 74.54% <0.00%> (-0.46%) :arrow_down:
internal/proxy/templates.go 100.00% <0.00%> (ø)
internal/pkg/aead/mock_cipher.go 0.00% <0.00%> (ø)
internal/pkg/groups/mock_cache.go 0.00% <0.00%> (ø)
... and 46 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update a1b1b74...171ce40. Read the comment docs.

danbf commented 2 years ago

seems to be working

Screen Shot 2021-07-23 at 12 34 30 AM
danbf commented 2 years ago

will test tomorrow to ensure they actually run on the platforms

danbf commented 2 years ago

ok got it running in stage and it seems fine, both sso_proxy and sso_auth