LukeMathWalker / LukeMathWalker/cargo-chef
FR: Provide override flag for terminal check
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 2.7k
- Forks
- 146
- PR merge metrics
- No merged PRs in 30d
Description
My cook stage in failing inside a [Kaniko](https://github.com/GoogleContainerTools/kaniko) automated builder running inside a docker container, it seems to have fooled `atty::is(atty::Stream::Stdout)`
It would be helpful to have a flag to force it to continue.
Output:
```
INFO[0102] Taking snapshot of full filesystem...
INFO[0108] cmd: /bin/sh
INFO[0108] args: [-c cargo chef cook --recipe-path recipe.json]
INFO[0108] Running: [/bin/sh -c cargo chef cook --recipe-path recipe.json]
WARNING stdout appears to be a terminal.
cargo-chef is not meant to be run in an interactive environment and will overwrite some existing files (namely any `lib.rs`, `main.rs` and `Cargo.toml` it finds).
To continue anyway, type `yes`: error building image: error building stage: failed to execute command: waiting for process to exit: exit status 1
exit status 1
```
If you have a preferred name for the flag, I can make a PR.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No file or test is named. Start by locating the terminal check that emits the stdout warning and the command-line argument handling around it; reproduce the Kaniko-in-Docker failure described above. Done means an override flag lets this non-interactive build continue when the terminal check is triggered.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, rust
- Domain
- build-system, cli
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100