[Bug]: rosetta is enabled by default on first install, without checking or verifying that rosetta is installed
- Dominant language
- Swift
- Stars
- 49.9k
- Forks
- 1.8k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 22
Description
### I have done the following
- [x] I have searched the existing issues
- [ ] If possible, I've reproduced the issue using the 'main' branch of this project
### Steps to reproduce
I recently did a fresh install of Container using homebrew on a new machine that hadn't been set up previously. (Fresh Tahoe 26.2 installation on a Mac mini v4).
- create a `Containerfile`:
```
FROM swift:6.2
RUN apt -q update && apt -q dist-upgrade -y
```
- `container build -t trial .`
### Current behavior
When I did an initial `container build .` on my project, the buildkit process immediately errored out. Digging around, and searching the logs it seems that rosetta is "on by default" for a fresh installation, but I didn't have rosetta installed.
I'd like to suggest that either the system should check for rosetta and potentially prompt to install it when it fires up, if the setting on "true" should be maintained, or that the default is changed to "false" and the documentation provided for how to install and enable Rosetta for acceleration of x86_64 builds.
The particular build I was trying to make was an arm64 build, so that it failed straight off was a bit of a surprise.
My workaround was to use:
```bash
container system property set build.rosetta false
```
Which I found in the comments of https://github.com/apple/container/issues/103
### Expected behavior
The build should have completed without an error.
### Environment
```markdown
- OS: Tahoe 26.2
- Xcode: 26.2 (17C52)
- Container: 0.8.0
```
### Relevant log output
```shell
N/A
```
### Code of Conduct
- [x] I agree to follow this project's Code of Conduct
Contributor guide
Research direction
Start by reproducing the failure with the provided Containerfile and `container build -t trial .` on a fresh setup, then inspect how the `build.rosetta` property is initialized and consumed. Compare the default behavior with `container system property set build.rosetta false`; done means an arm64 build does not fail when Rosetta is unavailable, with the chosen default or installation guidance documented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- macos, swift
- Domain
- build-system, cli, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100