{"action":"created","issue":{"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/925","labels_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/925/labels{/name}","comments_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/925/comments","events_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/925/events","html_url":"https://github.com/GoogleCloudPlatform/gcloud-node/issues/925","id":115334186,"number":925,"title":"Add API to create preemptible VMs","user":{"login":"gabipetrovay","id":1170398,"avatar_url":"https://avatars.githubusercontent.com/u/1170398?v=3","gravatar_id":"","url":"https://api.github.com/users/gabipetrovay","html_url":"https://github.com/gabipetrovay","followers_url":"https://api.github.com/users/gabipetrovay/followers","following_url":"https://api.github.com/users/gabipetrovay/following{/other_user}","gists_url":"https://api.github.com/users/gabipetrovay/gists{/gist_id}","starred_url":"https://api.github.com/users/gabipetrovay/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gabipetrovay/subscriptions","organizations_url":"https://api.github.com/users/gabipetrovay/orgs","repos_url":"https://api.github.com/users/gabipetrovay/repos","events_url":"https://api.github.com/users/gabipetrovay/events{/privacy}","received_events_url":"https://api.github.com/users/gabipetrovay/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-05T17:30:46Z","updated_at":"2015-11-05T17:35:52Z","closed_at":null,"body":"The [createVM](https://googlecloudplatform.github.io/gcloud-node/#/docs/v0.24.1/compute/zone?method=createVM) API method does not seem to expose the `--preemptible` option of the command line tool:\r\n\r\n```\r\ngcloud compute instances create --preemptible ...\r\n```\r\n\r\nIs this achieved in another way or is it missing?"},"comment":{"url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/comments/154132566","html_url":"https://github.com/GoogleCloudPlatform/gcloud-node/issues/925#issuecomment-154132566","issue_url":"https://api.github.com/repos/GoogleCloudPlatform/gcloud-node/issues/925","id":154132566,"user":{"login":"stephenplusplus","id":723048,"avatar_url":"https://avatars.githubusercontent.com/u/723048?v=3","gravatar_id":"","url":"https://api.github.com/users/stephenplusplus","html_url":"https://github.com/stephenplusplus","followers_url":"https://api.github.com/users/stephenplusplus/followers","following_url":"https://api.github.com/users/stephenplusplus/following{/other_user}","gists_url":"https://api.github.com/users/stephenplusplus/gists{/gist_id}","starred_url":"https://api.github.com/users/stephenplusplus/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephenplusplus/subscriptions","organizations_url":"https://api.github.com/users/stephenplusplus/orgs","repos_url":"https://api.github.com/users/stephenplusplus/repos","events_url":"https://api.github.com/users/stephenplusplus/events{/privacy}","received_events_url":"https://api.github.com/users/stephenplusplus/received_events","type":"User","site_admin":false},"created_at":"2015-11-05T17:35:52Z","updated_at":"2015-11-05T17:35:52Z","body":"Give this a shot:\r\n\r\n```js\r\nzone.createVM('new-vm-name', {\r\n  // ... options ...\r\n  scheduling: {\r\n    preemptible: true\r\n  }\r\n}, function(err, vm, operation, apiResponse) {});\r\n```\r\n\r\nThe second argument to `createVM` is the same object that is outlined here: https://cloud.google.com/compute/docs/reference/latest/instances -- so in theory, if that supports what you need, so do we :)"}}