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

[image] create. Add --os-disk-caching parameter. #7919

Merged
merged 3 commits into from
Nov 29, 2018

Conversation

adewaleo
Copy link
Contributor

@adewaleo adewaleo commented Nov 26, 2018

This parameter is used if the source is not a vm (i.e source is is disk blob, managed os disk or os snapshot). It is not currently possible to modify the os disk caching or any attribute of the os disk when creating an image from a VM. See #7648.


This checklist is used to make sure that common guidelines for a pull request are followed.

  • The PR has modified HISTORY.rst describing any customer-facing, functional changes. Note that this does not include changes only to help content. (see Modifying change log).

  • I adhere to the Command Guidelines.

@adewaleo adewaleo changed the title [image] Add --os-disk-caching parameter to image create [image] add --os-disk-caching parameter to image create Nov 26, 2018
@adewaleo adewaleo changed the title [image] add --os-disk-caching parameter to image create [image] create. Add --os-disk-caching parameter. Nov 26, 2018
@adewaleo
Copy link
Contributor Author

@closes #7655

@@ -114,6 +114,7 @@ def load_arguments(self, _):
c.argument('zone_resilient', min_api='2017-12-01', arg_type=get_three_state_flag(), help='Specifies whether an image is zone resilient or not. '
'Default is false. Zone resilient images can be created only in regions that provide Zone Redundant Storage')
c.argument('storage_sku', arg_type=disk_sku, help='The SKU of the storage account with which to create the VM image. Unused if source VM is specified.')
c.argument('os_disk_caching', arg_type=get_enum_type(CachingTypes), help="Storage caching type for the image's OS disk. Default: None")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You likely don't need the Default: None in the help. Most optional parameters will default to a null value.

Copy link
Contributor Author

@adewaleo adewaleo Nov 27, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@williexu, I mentioned the default value used, to keep in line with the os-disk-caching parameter's help text and behavior in VM create. The help text specifies that the default os disk caching is "ReadWrite".

One of the os caching enum's values is the string "None" (not null). I think it would be good to let users know what default os_disk_caching is used to create an image if the option is not used, even if in this case it is "None". I will update the code to explicitly use the enum's "None" value, if os caching is unspecified.

@adewaleo
Copy link
Contributor Author

@yugangw-msft, is this good to merge?

@adewaleo adewaleo added this to the Sprint 50 milestone Nov 28, 2018
@yugangw-msft yugangw-msft merged commit 39d51fa into Azure:dev Nov 29, 2018
williexu pushed a commit to williexu/azure-cli that referenced this pull request Dec 4, 2018
williexu pushed a commit that referenced this pull request Dec 6, 2018
* fix live tests for sas token urls to use datetime (#7866)

* Convert test back to scenario test. (#7862)

* Remove unused scripts. (#7860)

* fix get curren user id azure-graphrbac Breaking change fixes #7839 (#7864)

* Use knack 0.5.1. (#7780)

* test: make webjob tests record only as create command is unavailable (#7870)

* Deprecate expand param. (#7868)

* Updated help.py - generate-sas example (#7873)

Added MacOS example for generating SAS token with expiration time. The call to the date function `date -d` works on Linux, but not on MacOS. I provided MacOS sample.

* Low priority vmss test and help update. (#7882)

Updated help text and test location for low priority vmss

* Added --force to az vm restart. Added simple test. (#7885)

* Fix requests version > 2.20 (#7858)

* Bump CLI versions

* [vm] Enable password and ssh key authentication during linux VM creation (#7863)

* authentication-type can be set to all to permit both ssh key and password authentication

* Added tests and updated authentication type validation error.

* Added history entry, bumped version. Checked out file recording from dev branch.

* Addressed PEP8 issues.

* Updated test_vm_defaults auth tests.

* Updated other profile's unittests.

* Now infers authentication_type, other updates. Do not need to explicitly pass  all.

* Updated help text.
Fix conflict by checking out ephemeral os disk recording from dev branch.

* Style changes.

* Properly handle parsing of ids from -o tsv on windows. (#7898)

* Properly handle parsing of ids from -o tsv on windows.

* Removed unused import.

* [Storage] bump mgmt sdk version to 3.1.0 and set new api-version to use. (#7869)

* changed api-version in recordings and set to new ver of sdk

* version bump and history

* fix immutability test

* re-record all

* fixed recordings

fix recording

* bumped version after release

* test: live test fixes in appservice, vm, resource (#7899)

* ci: fix build break (#7900)

* Updated adls version (#7859)

* core: support cross tenant resource provisioning for multi-tenant service principal (#7916)

* core: fix the error on matching SP creds (#7923)

* resource: fix live test failure of policyset (#7922)

* [CI] reenable extension checking in CI (#7933)

* reenable extension checking in CI

minor edit to get travis to run

edit

* minor edit

* BotService: Bugfixing, code refactoring, reorganization and UX revamping (#7924)

* Close #7528. (#7920)

* Minor updates to core/generate_ssh_keys and batchai/_generate_ssh_keys (#7895)

* [image] create. Add --os-disk-caching parameter. (#7919)

* graph: support custom key identifier (#7913)

* support key-id description

* linter error fixes

* consolidate

* use official sdk

* update history

* BotService: fix tests, improve test robustness and update recordings (#7941)

* BotService: fix tests, mprove test robustness and update recordings

* BotService; fixing tests

* BotService: Update recordings

* webapp: Adding support for az webapp up (#7930)

* core: fix a breaking in kv when run under service principal (#7946)

* Disable version check from CI. (#7958)

* test: add test coverage for regression from auth (#7949)

* core: fix a breaking in kv when run under service principal

* test: add test coverage for regression from auth

* [AKS] Remove "(PREVIEW)" from AAD arguments  (#7960)

* [AKS] Remove "(PREVIEW)" from AAD arguments

* Bump module version and update HISTORY.rst

* Bug fixes for azure-cli-botservice (#7956)

* Az bot: fix bug when publishing Node.js bots, fix minor bugs

* Az bot: rerecord BotTests

* Az bot: fix static check error

* [core] Updated location help text (#7951)

* Updated location help text.

* Update parameters.py

* EventHubs help fixes (#7961)

* EventHubs help fixes

#Fixes 7937. Fixes #7938.

* Update _help.py

* Fixes for VPN Client Generate (#7962)

* Remove mock dependency.

* Fix linter issues.

* Condense the table format for task list and change all column headers to NAME
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.

3 participants