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

Adding feature to export snapshots instead of images. #583

Merged
merged 7 commits into from
Apr 2, 2019
Merged

Adding feature to export snapshots instead of images. #583

merged 7 commits into from
Apr 2, 2019

Conversation

bebattis
Copy link
Contributor

This allows for non-generalized (or non-sysprepped) osStates to be copied and deployed across regions. Will work as approved work around for copying VMs across regions which need to maintain identical runtimes.


Spoke with @tamirkamara on this previously offline. I was able to get the extension configured locally with the Azdev tools and ran a quick test to replicate a single region. This was successful. As far as development best practices, there may be a better way to do this, but for now I've essentially added two if/else statements and the switch parameter --export-as-snapshot which will 1) skip the image creation, and 2) place the temp snapshots into the target_resource_group vs the transient_resource-group depending on what the desired output is.

LMK if there is anything else that needs testing or improvement. Feel free to reach out again directly.

… non-generalized osStates to be copied and deployed across regions.
@azuresdkci
Copy link

If this PR is for a new extension or change to an existing extension, use the following to try out the changes in this PR:

docker run -it microsoft/azure-cli:latest
export EXT=<NAME>
pip install --upgrade --target ~/.azure/cliextensions/$EXT "git+https://github.com/bebattis/azure-cli-extensions.git@copy-snapshot-feature#subdirectory=src/$EXT&egg=$EXT"

@bebattis
Copy link
Contributor Author

bebattis commented Mar 19, 2019

EDIT: Needed to add this line to the create_target.py

Not too sure on this error... should I un-comment "pylint: disable=too-many-statements" ?

@tjprescott tjprescott merged commit 5a25c81 into Azure:master Apr 2, 2019
ShreyaAnand pushed a commit to ShreyaAnand/azure-cli-extensions that referenced this pull request Dec 31, 2024
[connectedmachine] release 2024-07-10 stable api
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

Successfully merging this pull request may close these issues.

6 participants