You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Provide an official ARM docker image and/or provide documentation for building on ARM #1861
Would it be possible to get an official Docker image of Envoy on ARM or at least some documentation on how to build it?
My team and I have tried off and on to build Envoy on ARM using the Bazel build process without any luck. Its challenging to say the least. I just saw a PR #1795 by @costinm dated a couple weeks ago based on the issue #1781 that talked about building it on ARM successfully after a few fixes. This is great news but we aren't sure how to duplicate it. @costinm mentioned that he used a custom CMAKE and a pi-cross-compiler to make it work. Documentation on this would be very helpful. Also, if there exist an image I could use for testing, then that would be very helpful too. Thanks again for such an awesome product!
Reacted by Edward Vielmetti, Rob Helgeson, Miles Fricker, Denys Vasyliev, Sven Haiges, Quentin Jaccarino, jared2501, Bryan Burgers, Drew Gonzales, briggySmalls and 29 more
Reacted by Alex Ellis, Surya Dantuluri and Sergio Alcantara
changed the title [-]Provide an official ARM docker image and/or provide documentation for building on ARM[/-][+]Provide an official ARM docker image and/or provide documentation for building on ARM label:"help wanted"[/+]on Oct 16, 2017
changed the title [-]Provide an official ARM docker image and/or provide documentation for building on ARM label:"help wanted"[/-][+]Provide an official ARM docker image and/or provide documentation for building on ARM Label: Help Wanted[/+]on Oct 16, 2017
changed the title [-]Provide an official ARM docker image and/or provide documentation for building on ARM Label: Help Wanted[/-][+]Provide an official ARM docker image and/or provide documentation for building on ARM [Label: Help Wanted][/+]on Oct 16, 2017
changed the title [-]Provide an official ARM docker image and/or provide documentation for building on ARM [Label: Help Wanted][/-][+]Provide an official ARM docker image and/or provide documentation for building on ARM[/+]on Oct 16, 2017
@gizmochief7 it's been a little while, have you made progress? It sounds like you're building for 32-bit ARMv7; my particular interest is in arm64 builds.
@vielmetti It has been and I almost forgot about posting this. We did not have any further luck with this attempt and without any community help we decided to move past Envoy. We tried out another reverse proxy/side car project for micro services and it just worked out of the box on both 32-bit and 64-bit. So we haven't wasted any more time here. Sorry I couldn't be more help.
Sorry, didn't see this bug: my cmake files are here:
https://github.com/costinm/istio-build (tested on pi and android),
I'm using them with repo to get the deps ( start from
https://github.com/costinm/istio-repo )
There is another PR needed to compile head ( another option with 64bit int
) - will send it when I get back from vacation.
I've been running envoy on my home pi (for a personal server) for few
weeks, it's pretty stable and light, but I haven't
made any progress in automating the build, CircleCI doesn't seem to like my
build.
On Mon, Nov 20, 2017 at 8:44 PM, gizmochief7 ***@***.***> wrote:
@vielmetti <https://github.com/vielmetti> It has been and I almost forgot
about posting this. We did not have any further luck with this attempt and
without any community help we decided to move past Envoy. We tried out
another reverse proxy/side car project for micro services and it just
worked out of the box on both 32-bit and 64-bit. So we haven't wasted any
more time here. Sorry I couldn't be more help.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1861 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAFI6jvr_r5AMUuCa4cAUnkmziR4N3x5ks5s4lUkgaJpZM4P5-S8>
.
fwiw, I tried to build bazel on my pi (yes, it took several hours), and then built envoy on pi for armv7l 64bit. While envoy started up and was able to talk to http services, it had difficulty talking to certain https services (esp twitter). There seemed to be some boringssl issue that prevented ssl connections from working. My hunch was that it didn't compile properly. At that point, I gave up, because I had spent 4 solid days fighting bazel on pi.
I think the cross-compilation option is faster and less painful - and easy
to expand to other platforms.
Boringssl and most of the dependencies have native support for cmake (or
can be easily adapted) - one of the problems with building with
'bazel' on pi is that deps are not really built with bazel, so even if
bazel can cross-compile c++ code, it would still not help us, most of the
code comes from the libraries compiled with autoconf. Of course autoconf
also supports cross - but then I also wanted to run it on android,
and cmake is supported very nicely by the NDK.
It requires some periodic tweaking - adding the new envoy files and fixing
ocasional 32-bit regressions (so far only the flags package seems to be a
problem - not clear why), but it's a pretty fast build.
But I appreciate the pain and effort in straight-compiling and fighting
bazel :-)
On Tue, Nov 21, 2017 at 6:35 AM, Shriram Rajagopalan < ***@***.***> wrote:
fwiw, I tried to build bazel on my pi (yes, it took several hours), and
then built envoy on pi for armv7l 64bit. While envoy started up and was
able to talk to http services, it had difficulty talking to certain https
services (esp twitter). There seemed to be some boringssl issue that
prevented ssl connections from working. My hunch was that it didn't compile
properly. At that point, I gave up, because I had spent 4 solid days
fighting bazel on pi.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1861 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAFI6mUOLKwygzX6Xwx9LXYCxrEc7_oEks5s4t-fgaJpZM4P5-S8>
.
On Tue, Nov 21, 2017 at 9:23 AM, Costin Manolache ***@***.***> wrote:
I think the cross-compilation option is faster and less painful - and easy
to expand to other platforms.
Boringssl and most of the dependencies have native support for cmake (or
can be easily adapted) - one of the problems with building with
'bazel' on pi is that deps are not really built with bazel, so even if
bazel can cross-compile c++ code, it would still not help us, most of the
code comes from the libraries compiled with autoconf. Of course autoconf
also supports cross - but then I also wanted to run it on android,
and cmake is supported very nicely by the NDK.
It requires some periodic tweaking - adding the new envoy files and fixing
ocasional 32-bit regressions (so far only the flags package seems to be a
problem - not clear why), but it's a pretty fast build.
But I appreciate the pain and effort in straight-compiling and fighting
bazel :-)
On Tue, Nov 21, 2017 at 6:35 AM, Shriram Rajagopalan <
***@***.***> wrote:
> fwiw, I tried to build bazel on my pi (yes, it took several hours), and
> then built envoy on pi for armv7l 64bit. While envoy started up and was
> able to talk to http services, it had difficulty talking to certain https
> services (esp twitter). There seemed to be some boringssl issue that
> prevented ssl connections from working. My hunch was that it didn't compile
> properly. At that point, I gave up, because I had spent 4 solid days
> fighting bazel on pi.
>
> —
> You are receiving this because you were mentioned.
> Reply to this email directly, view it on GitHub
> <#1861 (comment)>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AAFI6mUOLKwygzX6Xwx9LXYCxrEc7_oEks5s4t-fgaJpZM4P5-S8>
> .
>
I've secured a Pine64 Rock64 SOC which is ARM8 / aarch64 and has 4GB of RAM. I've successfully
compiled Bazel 0.13.0. I'm not having any luck compiling Envoy.
I've leveraged @clnperezway of removing the Lua JIT.
I can't get her trick to use the locally installed Go to work go_register_toolchains(go_version="host"). When I use this Bazel uses a symbolic link to the installed Go tools (~/Library/go/pkg/tool/linux_arm64) and tries to compile Gazelle and protoc-gen-go and fails because link can't see gcc on $PATH. Installing these tools on the host don't fix the issue. I expect this is something to do with breaking the hermetic seal by using go_version="host".
I've modified source/extensions/extensions_build_config.bzl to only include a minimum number of extensions.
I'm using bazel --bazelrc=/dev/null build -s -c opt //source/exe:envoy-static.stripped --define google_grpc=disabled --define signal_trace=disabled --define hot_restart=disabled --verbose_failures as the build command with the following WORKSPACE.
This prevents the build automatically downloading Go for linux_amd64.
The build then fails with
ERROR: ~/.cache/bazel/_bazel_moderation/1d277edd85b03195d275adc4870a9bef/external/com_lyft_protoc_gen_validate/validate/BUILD:35:1: no such package '@com_github_golang_protobuf//ptypes/duration': no such package '@io_bazel_rules_go_repository_tools//': no such package '@go_sdk//': Unsupported host linux_amd64 and referenced by '@com_lyft_protoc_gen_validate//validate:go_default_library'
ERROR: Analysis of target '//source/exe:envoy-static.stripped' failed; build aborted: no such package '@com_github_golang_protobuf//ptypes/duration': no such package '@io_bazel_rules_go_repository_tools//': no such package '@go_sdk//': Unsupported host linux_amd64
My suspicion is that the lyft/protoc-gen-validate is hard coded for linux_amd64 (or considering compilation works on MacOS / Darwin maybe it just doesn't support ARM).
I'll try and help. I don't have much ARM experience but a coworker (@tophj-ibm) does. So we'll try to put our heads together on this one. Any progress we can make would be great. We'd also like to have a ppc64le docker image.
wonder twins unite?
My first guess is that something in cc_configure works differently for ARM. I ran into some things where, when using certain flags, gcc would behave differently for power than it did for x86. envoy, for the last release, seems to have come to rely a lot more on how bazel configured the gcc toolchain and did a little less customization. That got rid of almost all the issues I was seeing, but maybe there is some more tweaking needed for ARM.
For your WORKSPACE file, what's the logic behind including the call to `go_download_sdk'?
@CelsoSantos It's been a while, but IIRC the command I ran back on the 18th of May worked and generated a Docker image (which I uploaded to Docker Hub as al45tair/envoy-arm64). It seems to work.
@moderation@carmiac It's probably worth getting some time on an ARM64 server machine rather than building on a Pi. Even if you don't have access to one at work (I'm lucky in that regard), you can spin them up in AWS — there are Graviton and Graviton2 instances available, I believe — and they'll build it a lot faster than a Pi will.
@al45tair I'm pretty happy with my local RPi4 dev environment. After the initial build the subsequent incremental builds are relatively quick and compiling out all the extensions you don't need works well. I'm in a very small minority of people who don't think Docker helps with anything so I'm building Bazel and Envoy straight on the RPi4
Thanks @vielmetti. Looks like they need to work on their automation a bit as the latest release 3.4.1 isn't yet available. But definitely looks promising
Activity
[-]Provide an official ARM docker image and/or provide documentation for building on ARM[/-][+]Provide an official ARM docker image and/or provide documentation for building on ARM label:"help wanted"[/+][-]Provide an official ARM docker image and/or provide documentation for building on ARM label:"help wanted"[/-][+]Provide an official ARM docker image and/or provide documentation for building on ARM Label: Help Wanted[/+][-]Provide an official ARM docker image and/or provide documentation for building on ARM Label: Help Wanted[/-][+]Provide an official ARM docker image and/or provide documentation for building on ARM [Label: Help Wanted][/+][-]Provide an official ARM docker image and/or provide documentation for building on ARM [Label: Help Wanted][/-][+]Provide an official ARM docker image and/or provide documentation for building on ARM[/+]vielmetti commentedon Nov 20, 2017
@gizmochief7 it's been a little while, have you made progress? It sounds like you're building for 32-bit ARMv7; my particular interest is in arm64 builds.
gizmochief7 commentedon Nov 21, 2017
@vielmetti It has been and I almost forgot about posting this. We did not have any further luck with this attempt and without any community help we decided to move past Envoy. We tried out another reverse proxy/side car project for micro services and it just worked out of the box on both 32-bit and 64-bit. So we haven't wasted any more time here. Sorry I couldn't be more help.
costinm commentedon Nov 21, 2017
rshriram commentedon Nov 21, 2017
fwiw, I tried to build bazel on my pi (yes, it took several hours), and then built envoy on pi for armv7l 64bit. While envoy started up and was able to talk to http services, it had difficulty talking to certain https services (esp twitter). There seemed to be some boringssl issue that prevented ssl connections from working. My hunch was that it didn't compile properly. At that point, I gave up, because I had spent 4 solid days fighting bazel on pi.
costinm commentedon Nov 21, 2017
costinm commentedon Nov 21, 2017
moderation commentedon May 16, 2018
I've secured a Pine64 Rock64 SOC which is ARM8 / aarch64 and has 4GB of RAM. I've successfully
compiled Bazel 0.13.0. I'm not having any luck compiling Envoy.
I've leveraged @clnperez way of removing the Lua JIT.
I can't get her trick to use the locally installed Go to work
go_register_toolchains(go_version="host"). When I use this Bazel uses a symbolic link to the installed Go tools (~/Library/go/pkg/tool/linux_arm64) and tries to compile Gazelle and protoc-gen-go and fails becauselinkcan't seegccon $PATH. Installing these tools on the host don't fix the issue. I expect this is something to do with breaking the hermetic seal by usinggo_version="host".I've modified
source/extensions/extensions_build_config.bzlto only include a minimum number of extensions.I'm using
bazel --bazelrc=/dev/null build -s -c opt //source/exe:envoy-static.stripped --define google_grpc=disabled --define signal_trace=disabled --define hot_restart=disabled --verbose_failuresas the build command with the following WORKSPACE.This prevents the build automatically downloading Go for
linux_amd64.The build then fails with
My suspicion is that the lyft/protoc-gen-validate is hard coded for linux_amd64 (or considering compilation works on MacOS / Darwin maybe it just doesn't support ARM).
Any help from Bazel wizards like @jmillikin-stripe or from people that have tried non amd64 compilation like @clnperez @costinm @rshriram would be great.
vielmetti commentedon May 16, 2018
Issue noted in https://github.com/lyft/protoc-gen-validate/issues/75 - there are definitely some hard-coded dependencies in lyft/protoc-gen-validate to amd64 binaries.
clnperez commentedon May 17, 2018
I'll try and help. I don't have much ARM experience but a coworker (@tophj-ibm) does. So we'll try to put our heads together on this one. Any progress we can make would be great. We'd also like to have a ppc64le docker image.
wonder twins unite?
My first guess is that something in cc_configure works differently for ARM. I ran into some things where, when using certain flags, gcc would behave differently for power than it did for x86. envoy, for the last release, seems to have come to rely a lot more on how bazel configured the gcc toolchain and did a little less customization. That got rid of almost all the issues I was seeing, but maybe there is some more tweaking needed for ARM.
For your WORKSPACE file, what's the logic behind including the call to `go_download_sdk'?
94 remaining items
al45tair commentedon Jul 14, 2020
@CelsoSantos It's been a while, but IIRC the command I ran back on the 18th of May worked and generated a Docker image (which I uploaded to Docker Hub as al45tair/envoy-arm64). It seems to work.
@moderation @carmiac It's probably worth getting some time on an ARM64 server machine rather than building on a Pi. Even if you don't have access to one at work (I'm lucky in that regard), you can spin them up in AWS — there are Graviton and Graviton2 instances available, I believe — and they'll build it a lot faster than a Pi will.
moderation commentedon Jul 14, 2020
@al45tair I'm pretty happy with my local RPi4 dev environment. After the initial build the subsequent incremental builds are relatively quick and compiling out all the extensions you don't need works well. I'm in a very small minority of people who don't think Docker helps with anything so I'm building Bazel and Envoy straight on the RPi4
lizan commentedon Jul 14, 2020
I wouldn't be comfortable saying it is stable until it passes most of our test suite on arm64.
vielmetti commentedon Jul 15, 2020
A note that Bazel 3.4.0 now ships with official arm64 binaries -
bazelbuild/bazel#8833 (comment)
That may save you a build step, @moderation , if you can adapt to any changes associated with the Bazel point release at 3.4.0.
moderation commentedon Jul 15, 2020
Thanks @vielmetti. Looks like they need to work on their automation a bit as the latest release 3.4.1 isn't yet available. But definitely looks promising
ci: enable full test on arm64 (#12124)
ci: enable full test on arm64 (envoyproxy#12124)
chore(website): update frontpage version from 0.4 to 0.5 (#1861)