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

az image create is not working with a managed disk ID #6227

Closed
colemickens opened this issue Apr 26, 2018 · 7 comments
Closed

az image create is not working with a managed disk ID #6227

colemickens opened this issue Apr 26, 2018 · 7 comments

Comments

@colemickens
Copy link
Contributor

az image create -n nixos-image-16.09.1694.019dcc3-x86_64-linux.vhd -g aznixos --source /subscriptions/aff271ee-e9be-4441-b9bb-42f5af4cbaeb/resourceGroups/aznixos/providers/Microsoft.Compute/disks/nixos-image-16.09.1694.019dcc3-x86_64-linux.vhd --os-type linux

results in:

The URI /subscriptions/aff271ee-e9be-4441-b9bb-42f5af4cbaeb/resourceGroups/aznixos/providers/Microsoft.Compute/disks/nixos-image-16.09.1694.019dcc3-x86_64-linux.vhd does not look to be correct blob URI.

The examples clearly show creating an Image from a Managed Disk. Not sure what's going on.

@yugangw-msft
Copy link
Contributor

Fix by #6220

@colemickens
Copy link
Contributor Author

colemickens commented Apr 26, 2018 via email

@yugangw-msft yugangw-msft reopened this Apr 26, 2018
@yugangw-msft
Copy link
Contributor

let me cross check, which I should have done when I submitted the fix, but I forgot

@colemickens
Copy link
Contributor Author

AFAICT this also affects az disk too:

$ az disk create -n nixos-image-16.09.1694.019dcc3-x86_64-linux-vhd -g aznixos --source https://aznixos.blob.core.windows.net/aznixos/nixos-image-16.09.1694.019dcc3-x86_64-linux-vhd --sku Premium_LRS
usage error: --source {SNAPSHOT | DISK} | --source VHD_BLOB_URI [--source-storage-account-id ID]

$ az disk create -n nixos-image-16.09.1694.019dcc3-x86_64-linux-vhd -g aznixos --source https://aznixos.blob.core.windows.net/aznixos/nixos-image-16.09.1694.019dcc3-x86_64-linux.vhd --sku Premium_LRS

[works]

Note the only difference is the blob having a -vhd or .vhd suffix. I had tried to change the suffix to work around this issue... and just ran into a different version of it. :/

@colemickens
Copy link
Contributor Author

(This is because I have a single variable "TARGET" that is the blob name, the disk name, and the image name. So I'm either burnt because the disk/image name end in .vhd and confuse other commands, or I'm burnt because the blob won't end in .vhd and thus I won't be able to make a Disk out of it.)

@yugangw-msft
Copy link
Contributor

yugangw-msft commented Apr 26, 2018

Disk/snapshot/image were handled through the old PR this morning. The recent PR handles the vm and vmss

@colemickens
Copy link
Contributor Author

Okay, didn't realize it got disk+image. Thanks so much, once again you fixed it hours (minutes maybe even) before I filed it. 😀 Looking forward to a new release. Thanks @yugangw-msft !

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