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

[Bug]: Protocol buffer on arm64 - Exec format error #83

Open
sboett-dev opened this issue Dec 9, 2024 · 1 comment
Open

[Bug]: Protocol buffer on arm64 - Exec format error #83

sboett-dev opened this issue Dec 9, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@sboett-dev
Copy link

sboett-dev commented Dec 9, 2024

Feature id and version

1

Dev Container base Image

mcr.microsoft.com/vscode/devcontainers/base:bookworm

What happened?

I work on an arm64 machine and need protoc in my Dev Container. I added it with

"ghcr.io/devcontainers-extra/features/protoc:1": {
    "version": "29.1"
}

This leads to

protoc --version
bash: /usr/local/bin/protoc: cannot execute binary file: Exec format error

When I remove the feature from devcontainer.json and add apt-get install -y protobuf-compiler to my Dev Container Dockerfile instead, protoc is executable.

Relevant log output

bash: /usr/local/bin/protoc: cannot execute binary file: Exec format error
@sboett-dev sboett-dev added the bug Something isn't working label Dec 9, 2024
@koralowiec
Copy link
Member

Thanks for the bug report!

At first glance, as the feature uses gh-release feature under the hood, it may be an issue with filtering by nanolayer. I will take a deeper look

In meantime, if the installation via apt-get works for you, you can use apt-get packages feature to install the package:

{
	"name": "Ubuntu",
	"image": "mcr.microsoft.com/devcontainers/base:ubuntu",
	"features": {
		"ghcr.io/devcontainers-extra/features/apt-get-packages:1": {
			"packages": "protobuf-compiler"
		}
	}
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants