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
Cannot edit/duplicate a container when registry is not registered in Portainer #1140
Comments
@masudak Can you open the browser developer console and check if there is any error ? Also where is this error displayed 'Cannot read property 'URL' of undefined' ? In a red notification message? |
Console had this error.
Yes, |
@masudak is it possible for you to give us the all the information about the container you wanted to edit/duplicate? All the parameters that you put in the container creation view? Or was it a container created from the CLI ? |
There is one thing I found. And if I used docker-compose like this, it worked too.
But if I used this compose file such as using GCR, it failed.
|
Linked to Registry no ? |
Is it necessary to be known to portainer for our registry? Or is there any tips to make it known to portainer? |
Right this might be problematic indeed, I'll investigate a bit. Thanks for the details @masudak EDIT: normally, if the registry is not known by Portainer, it should default to Dockerhub. |
Thank you so much, let me know if I should investigate and submit more detail. |
@msudak
Then when in Duplicate/Edit view, verify that the image and registry are ok before pressing "Start container" |
@WTFKr0 I added the registry on Registries menu, and then it worked without any errors. Thank you so much!! I hope it will work without any manual operations! |
I've created a PR to solve this issue (#1143). It's not really a fix as we cannot create a container from an unknow registry using the current registry management implementation in Portainer. Instead, this PR will display a warning message and prevent the creation of the container by disabling the start container button. |
I think you can |
So I think the fix can be : |
Your approach is better than now as a first measure, but how about making enabling to set command line option for a private registry such as below.
|
@WTFKr0 If we default to Dockerhub with the full path in the image text input, this will not create the image expected by the user. So the user will probably have to create the registry right after that. @masudak I'm not keen to support these kind of options on the CLI. I'd rather have CLI flags that alters the status of the Portainer binary not the data. We can still use the HTTP API to automate the creation of registries. I'm thinking that there might be a way to circumvent the existing registry implementation when duplicating/editing a container, I can have a look. |
Okay, I got it.
Thanks, it helps me a lot! |
#1143 has been merged as a temporary measure (container duplication is still considered experimental) but I'll keep this issue open as we should find a way to use unregistered registries as well. |
Maybe I discovered a related bug; Docker.io seems not to be recognized as the Dockerhub-Registry and the same Error occurs.
Workaround: If I use in step 4 the image tag I would try to recognize docker.io as dockerhub, so that the registry is registered. |
Can confirm Knall0 issue... "The Docker registry for the arm32v7/wordpress:latest image is not registered inside Portainer, you will not be able to create a container. Please register that registry first. " While trying to duplicate/Edit the container. |
This happens for pretty much all of my images. |
Temporary solution: Add the url docker.io in the Registries section. |
I can confirm this happens for images from Docker Hub as well. Portainer version 1.16.4 The workaround from @lweb20 did not work for me. |
This issue has been marked as stale as it has not had recent activity, it will be closed if no further activity occurs in the next 7 days. If you believe that it has been incorrectly labelled as stale, leave a comment and the label will be removed. |
Since no further activity has appeared on this issue it will be closed. If you believe that it has been incorrectly closed, leave a comment and mention @itsconquest. One of our staff will then review the issue. |
Description
I started to use portainer from today, and want to edit environment variables through webui against a running container, but I can't with this error message.
Steps to reproduce the issue:
/#/containers/
, I choose a running container.Duplicate/Edit
buttonEnv
tabStart container
buttonReplace
.docker logs optimistic_fermi(portainer's container name)
was no output when this error was shown.Is there any way to trace any other logs?
Technical details:
GCP instance
docker run -p 9000:9000 portainer/portainer
):Target Swarm version (if applicable):
not used.
Browser:
Google Chrome 60.0.3112.101(Official Build)
on Mac 10.12.6
The text was updated successfully, but these errors were encountered: