-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Skaffold init asks user to write skaffold.yaml #1091
Conversation
Codecov Report
@@ Coverage Diff @@
## master #1091 +/- ##
=========================================
- Coverage 42.43% 42.24% -0.2%
=========================================
Files 72 72
Lines 3280 3295 +15
=========================================
Hits 1392 1392
- Misses 1754 1769 +15
Partials 134 134
Continue to review full report at Codecov.
|
reader := bufio.NewReader(os.Stdin) | ||
confirmLoop: | ||
for { | ||
fmt.Fprintf(out, "Do you want to write this configuration to %s? [y/n]: ", opts.ConfigurationFile) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is breaking integration tests - we need a non-interactive way (-y):
--- FAIL: TestInit/microservices (0.02s)
run_test.go:352: running init: Running [skaffold init -f skaffold.yaml.out -a leeroy-app/Dockerfile=gcr.io/k8s-skaffold/leeroy-app -a leeroy-web/Dockerfile=gcr.io/k8s-skaffold/leeroy-web]: stdout apiVersion: skaffold/v1alpha4
kind: Config
build:
artifacts:
- image: gcr.io/k8s-skaffold/leeroy-app
context: leeroy-app
- image: gcr.io/k8s-skaffold/leeroy-web
context: leeroy-web
deploy:
kubectl:
manifests:
- leeroy-app/kubernetes/deployment.yaml
- leeroy-web/kubernetes/deployment.yaml
Do you want to write this configuration to skaffold.yaml.out? [y/n]: , stderr: time="2018-10-04T07:51:21Z" level=fatal msg="reading user confirmation: EOF"
, err: exit status 1: exit status 1, output: apiVersion: skaffold/v1alpha4
kind: Config
build:
artifacts:
- image: gcr.io/k8s-skaffold/leeroy-app
context: leeroy-app
- image: gcr.io/k8s-skaffold/leeroy-web
context: leeroy-web
deploy:
kubectl:
manifests:
- leeroy-app/kubernetes/deployment.yaml
- leeroy-web/kubernetes/deployment.yaml
Do you want to write this configuration to skaffold.yaml.out? [y/n]:
run_test.go:342: error removing generated skaffold yaml: remove ../examples/microservices/skaffold.yaml.out: no such file or directory
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's a --force
that I forgot to use here.
Fix GoogleContainerTools#1090 Signed-off-by: David Gageot <[email protected]>
Fix #1090
Signed-off-by: David Gageot [email protected]