-
Notifications
You must be signed in to change notification settings - Fork 2
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
Display help and usage message #3
Comments
Also export command did not work for me. ./docker-migrate.py export /tmp/export/Saving image docker.io/ubuntu:latest |
Hi! I've pushed a fixed version. It fixes the help message problem. I tried to replicate your export bug on my computer, but it worked fine. Did it create the export directory on your computer? |
If I just type ./docker-migrate.py (and no parameters), then export issue still happens for me. I think reason is that you are assuming that arguments have been passed and trying to access sys.argv[1]. But it is not there. I think instead look for number of arguments and if minimum number of arguments are not there, then display help message. |
I can still reproduce the "No Such file or Directory Issue". [root@vm2-f22 rhvgoyal-docker-migrate]# ./docker-migrate export /tmp/image-export/ I think problem here is the image name. It contains a "/". I think you will have to replace "/" with "-" or something like that. If you use "/" in file name, then it is treated as path in directory and "docker-io" directory is not present. |
You're right! Whoops, I thought I had fixed it, but I guess I missed a spot. Pushed my new fix; I think this one should work. ----- Original Message ----- If I just type ./docker-migrate.py (and no parameters), then export issue still happens for me. I think reason is that you are assuming that arguments have been passed and trying to access sys.argv[1]. But it is not there. I think instead look for number of arguments and if minimum number of arguments are not there, then display help message. Reply to this email directly or view it on GitHub: |
Are you running it as ./docker-migrate? I have to run it as ./docker-migrate.py Do we want it to work either way? You're right. That is a bug. I'll go take a look at it. Thanks for catching it! ----- Original Message ----- I can still reproduce the "No Such file or Directory Issue". [root@vm2-f22 rhvgoyal-docker-migrate]# ./docker-migrate export /tmp/image-export/ I think problem here is the image name. It contains a "/". I think you will have to replace "/" with "-" or something like that. If you use "/" in file name, then it is treated as path in directory and "docker-io" directory is not present. Reply to this email directly or view it on GitHub: |
Hi! I've fixed it now. I replace / with ~ (we already use - to separate tags from image names). If you can think of any other characters we'll need to parse out, please let me know! It doesn't seem to change the final image name when we reimport, which is good. I've pushed my fix. ----- Original Message ----- I can still reproduce the "No Such file or Directory Issue". [root@vm2-f22 rhvgoyal-docker-migrate]# ./docker-migrate export /tmp/image-export/ I think problem here is the image name. It contains a "/". I think you will have to replace "/" with "-" or something like that. If you use "/" in file name, then it is treated as path in directory and "docker-io" directory is not present. Reply to this email directly or view it on GitHub: |
If I type docker-migrate.py, I get following. I should instead get a help message with various options.
./docker-migrate.py
Traceback (most recent call last):
File "./docker-migrate.py", line 8, in
if sys.argv[1] == "export" :
IndexError: list index out of range
The text was updated successfully, but these errors were encountered: