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] kn faas deploy fails when used with quay.io #24

Open
nainaz opened this issue Oct 29, 2020 · 6 comments
Open

[bug] kn faas deploy fails when used with quay.io #24

nainaz opened this issue Oct 29, 2020 · 6 comments

Comments

@nainaz
Copy link
Contributor

nainaz commented Oct 29, 2020

Describe the bug
For node runtime, after running kn faas build . Running kn faas deploy fails with
Error: knative deployer failed to wait for the service to become ready: timeout: service 'testdaynodefunc' not ready after 60 seconds

To Reproduce
Steps to reproduce the behavior:

  1. kn faas init -l node
  2. kn faas build
  3. docker images | grep
  4. kn faas deploy

Expected behavior
successful deploy of the function

Screenshots

Deploying Function to cluster:
Creating Knative Service: testdaynodefunc
Waiting for Knative Service to become ready
Error: knative deployer failed to wait for the service to become ready: timeout: service 'testdaynodefunc' not ready after 60 seconds

docker images | grep testday
testdayquarkfunction latest fb2b0f91d03c 40 years ago 394MB

Desktop (please complete the following information):

  • OS: macOs
  • Browser if applicable [e.g. chrome, safari]

Additional context
Looks like push to quay.io is part of deploy step and since quay.io repo needs to be made public beforehand. This fails due to unavailability of the image.

@matejvasek
Copy link
Contributor

@nainaz isn't the repo private?

@matejvasek
Copy link
Contributor

matejvasek commented Oct 29, 2020

There is inconsistency deploy is prompting for registry whereas build is prompting for image. This should be unified. What should we do? @boson-project/core

Edit this belong to another issue.

@lance
Copy link
Member

lance commented Oct 29, 2020

@matejvasek the problem is that we have moved the push to a registry to happen in the deploy step. However, if you are using quay.io then your first deploy will always fail the first time. You can often make the repository public in time for Knative to not give up, but still that's non-optimal. We either need to move the push to a registry back into the build step, or somehow deal with quay.io being awful.

There is inconsistency deploy is prompting for registry whereas build is prompting for image

I don't think that is the case, is it? IIRC deploy doesn't prompt unless the image has not yet been built.

@lance
Copy link
Member

lance commented Oct 29, 2020

I don't think that is the case, is it? IIRC deploy doesn't prompt unless the image has not yet been built.

I was wrong about this. The deploy command does prompt if the image has not yet been built. But it prompts with the same thing that build prompts with.

@matejvasek
Copy link
Contributor

matejvasek commented Oct 29, 2020

I don't think that is the case, is it? IIRC deploy doesn't prompt unless the image has not yet been built.

@lance If you use -c flag you are prompted for registry, but value you enter there is ignore and value from faasyaml is used anyway, that's a bug.

@matejvasek
Copy link
Contributor

buildConfig: buildConfig{
			Registry: prompt.ForString("Registry for Function images", c.buildConfig.Registry),
		},

// vs
return buildConfig{
		Path:    prompt.ForString("Path to project directory", c.Path),
		Image:   prompt.ForString("Image name", imageName, prompt.WithRequired(true)),
		Verbose: c.Verbose,
		// Registry not prompted for as it would be confusing when combined with explicit image.  Instead it is
		// inferred by the derived default for Image, which uses Registry for derivation.
	}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants