Open
Description
Looks like browserstack-local binary is only compiled for x86_64 and ia32.
I'm on an an M1 mac successfully running multiple docker containers with selenium and browserstack, etc..., but I'm running into issues when trying to run browserstack-local.
$ uname -a
Linux 3d7e5f8f8bfb 5.10.76-linuxkit #1 SMP PREEMPT Mon Nov 8 11:22:26 UTC 2021 aarch64 GNU/Linux
And when I try to run browserstack-local I get the following:
qemu-x86_64: Could not open '/lib64/ld-linux-x86-64.so.2': No such file or directory
and
Error
Traceback (most recent call last):
File "/prefix/prefix/app/tests/test_web.py", line 41, in setUpClass
cls.bs_local.start(**cls.bs_local_args)
File "/usr/local/lib/python3.9/site-packages/browserstack/local.py", line 43, in start
self.binary_path = LocalBinary().get_binary()
File "/usr/local/lib/python3.9/site-packages/browserstack/local_binary.py", line 112, in get_binary
raise BrowserStackLocalError('BrowserStack Local binary is corrupt')
browserstack.bserrors.BrowserStackLocalError: BrowserStack Local binary is corrupt
Obviously because all my docker containers are running an ARM linux kernel, and there's only browserstack-local binaries for x86_64 and ia32
Activity
edwinclement08 commentedon Jul 12, 2022
by any chance, have you tried out https://github.com/browserstack/docker-browserstack-local
harish18051991 commentedon Mar 27, 2023
I am facing the same issue with nodejs library, did you get this issue fixed or have any work around.
yarramneedik17 commentedon Apr 11, 2023
I am facing similar issue, But I am not running on Docker, it is in my local I am getting the issue below
rahulHbrowserstack commentedon Apr 12, 2023
Hello @yarramneedik17 , this issue occurs when you have used wrong Accesskey. Check your Accesskey from the link https://www.browserstack.com/accounts/settings; and make the changes accordingly.
yarramneedik17 commentedon Apr 13, 2023
Thanks for the suggestion, I have fixed that issue, but we are seeing new issue.
juancferrer commentedon Apr 25, 2023
I'm still not able to run browserstacklocal inside an aarch64 docker container.
At first I was getting:
qemu-x86_64: Could not open '/lib64/ld-linux-x86-64.so.2': No such file or directory
I was able to get rid of the missing libraries by having something like the following in my Dockerfile
Now when I run the BrowserStackLocal binary, it just prints out
Bus error
to the terminal, and exitsWas hoping that installing all the x86-64 libraries would make it work, but that doesn't seem to be the case.
The core issue being that there are NOT any aarch64 builds for BrowserStackLocal.
You can see here: https://github.com/browserstack/browserstack-local-python/blob/master/browserstack/local_binary.py#L10
There's builds for mac (intel), linux 32+64 bit and windows. No builds for mac (apple silicon) or what I want, which is linux aarch64/arm64.
Looks like you're not able to use browserstack local if you're developing on aarch64 mac or linux. 👎🏼
[-]M1 Mac / aarch64 support[/-][+]Linux + Mac aarch64/arm64 support[/+]juancferrer commentedon Apr 28, 2023
@yarramneedik17 @harish18051991
I think I finally figured it out.
I'm successfully running BrowserStackLocal 8.9 x86-64 binary
inside a Linux aarch64 docker container
So to get everything working, you just need the
libstdc++6-amd64-cross
package, and make sure yourLD_LIBRARY_PATH
includes the path to the x86_64 librariesSo on my ubuntu/debian based docker image, I just had to do the following
and now inside that docker container, the BrowserStackLocal binary runs as expected.