-
-
Notifications
You must be signed in to change notification settings - Fork 42
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
Unable to delete the containers using sregistry-cli #329
Comments
hey @ashwinidr23 - I'd be happy to work on this for you! The error message above actually looks related to rate limiting. We could go back to this (what I consider deprecated) client, but another idea is to add the singularity delete library endpoint directly (which isn't currently implemented): https://sylabs.io/guides/3.5/user-guide/cli/singularity_delete.html I'm quite busy this week but I think I should be able to make some time to work on this later this month. In the mean time, I would strongly encourage you to figure out adding https! You can compile Singularity in a way to not require it, but it's much better that it's secure. |
Thank you very much. Either the sregistry-cli or singularity delete end point should help.
There were some certificate issues that I noticed the last time I tried to configure with HTTPS. I did not try later, but it is in my list to make it work.
|
hey @vsoch , PS: i did not get this error with http However- configuring the registry did not resolve the primary issue that i was facing (i.e., pulling/pushing/deleting images to sregistry using sregistry-cli or singularity) -bash-4.2$ sregistry delete registry://adr23/lolcow:2 when i use singularity: pull : works fine i did not find any details about deleting the containers using singularity in the document here : https://singularityhub.github.io/sregistry/docs/client#pancakes-installation i want to be able to delete containers using command-line either using sregistry-cli/singularity(which i can automate rather than using GUI). Thanks in advance! |
Okay let's work through your comments one by one! First, you are correct that the https docker-compose.yml file is missing the mount of the minio environment - I'll add that shortly in a PR. For sregistry, I don't consider sregistry-cli to be supported anymore - you should just be using Singularity. And then the 500 error indicates a server error, so you need to look at the uwsgi logs to see what that is. |
As far as I know, deleting containers with the Singularity client is not supported. But you could ask the hpcng folks if this is changed! |
Missing minio env is added: #334 |
here is the log for push error docker-compose logs --tail=30 uwsgi and when i look at the sregistry GUI, i find a build created after this but when i navigate to the container, it is empty. -bash-4.2$sregistry search gives the name of the file which was "not pushed" contents in images folder |
That error message tells us that the minio container is not running. Your next thing to debug is: docker-compose logs --tail=30 minio As I said before, the sregistry-cli command is not expected to work. |
[root@myvm sregistry]# docker-compose logs --tail=30 minio |
i did not find any errors in minio container |
Have you changed anything about the setup? If you follow the instructions in the documentation to use the |
i have not changed anything in the setup. [root@myvm sregistry]# ./mc config host ls local myminio play s3 but i do not get any logs. i tried to push a container while running the below command. but i cud not get any logs ! |
That’s the issue then - the request never reaches the Minio server, and that’s exactly what the 500 error is telling you. There is something off about your setup and you’ll have to debug. I would try shelling into the various containers, Minio and uwsgi, and seeing if you can see (ping) the others based on their hostnames that are supposed to be setup by Docker compose. You can also check the /etc/hosts file. If that works, the next step is to interactively create the Minio client from the uwsgi container (the file Minio.py) and test interactions with your Minio container. I suspect the first test won’t work and there is something off about the networking for your containers, but that’s just a hunch. |
do you mean to login to uwsgi container and install mc there and try to run trace there? |
I mean to shell into the uwsgi container, and then get an interactive python shell ( |
Here is my observation so far, [root@myvm sregistry]# ./mc config host add myminio http://127.0.0.1:9000 $MINIO_ACCESS_KEY $MINIO_SECRET_KEY however if i do not change the access key and secret key , i can get the sregistry up and running, but singularity pull/push does not seem to work as none of the requests are reaching minio in this case. |
I am unable to delete the containers in sregistryhub using sregistry-cli. however i can delete using GUI. but since i want to delete more containers at once i would like to use sregistry-cli for this.
i get the following error when i try to delete the repository
sregistry delete inadr/inadr-lolcow2:222
[client|registry] [database|sqlite:////home/inadr/.singularity/sregistry.db]
Are you sure you want to remove inadr/inadr-lolcow2:222?y
ERROR Beep boop! Internal Server Error: 500
these are the error logs
docker-compose logs --tail=10 -f uwsgi
Attaching to sregistry_uwsgi_1
uwsgi_1 | File "/usr/local/lib/python3.5/site-packages/ratelimit/decorators.py", line 27, in _wrapped
uwsgi_1 | increment=True)
uwsgi_1 | File "/usr/local/lib/python3.5/site-packages/ratelimit/utils.py", line 127, in is_ratelimited
uwsgi_1 | usage = get_usage_count(request, group, fn, key, rate, method, increment)
uwsgi_1 | File "/usr/local/lib/python3.5/site-packages/ratelimit/utils.py", line 154, in get_usage_count
uwsgi_1 | value = _SIMPLE_KEYSkey
uwsgi_1 | File "/usr/local/lib/python3.5/site-packages/ratelimit/utils.py", line 34, in
uwsgi_1 | 'ip': lambda r: r.META['REMOTE_ADDR'],
uwsgi_1 | AttributeError: 'Container' object has no attribute 'META'
uwsgi_1 | [pid: 43|app: 0|req: 1070/2027] 144.199.213.236 () {44 vars in 805 bytes} [Tue Nov 17 04:45:21 2020] DELETE /api/container/inadr3/inadr3-lolcow2:222 => generated 850 bytes in 16 msecs (HTTP/1.1 500) 4 headers in 142 bytes (1 switches on core 2)
I tried to figure out for a solution online, but i could not, any pointers please?
PS: i am still using sregistry-cli and not singularity remote feature because i am having trouble configuring with HTTPS due to certificate issues which are beyond my control at the moment!
The text was updated successfully, but these errors were encountered: