{"action":"created","issue":{"url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/157","labels_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/157/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/157/comments","events_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/157/events","html_url":"https://github.com/ansible/ansible-modules-core/issues/157","id":45136934,"number":157,"title":"Digital Ocean image/size/region slugs","user":{"login":"chbrown","id":360279,"avatar_url":"https://avatars.githubusercontent.com/u/360279?v=3","gravatar_id":"","url":"https://api.github.com/users/chbrown","html_url":"https://github.com/chbrown","followers_url":"https://api.github.com/users/chbrown/followers","following_url":"https://api.github.com/users/chbrown/following{/other_user}","gists_url":"https://api.github.com/users/chbrown/gists{/gist_id}","starred_url":"https://api.github.com/users/chbrown/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chbrown/subscriptions","organizations_url":"https://api.github.com/users/chbrown/orgs","repos_url":"https://api.github.com/users/chbrown/repos","events_url":"https://api.github.com/users/chbrown/events{/privacy}","received_events_url":"https://api.github.com/users/chbrown/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/feature_idea","name":"feature_idea","color":"006b75"},{"url":"https://api.github.com/repos/ansible/ansible-modules-core/labels/P2","name":"P2","color":"fad8c7"}],"state":"closed","locked":false,"assignee":{"login":"skottler","id":579876,"avatar_url":"https://avatars.githubusercontent.com/u/579876?v=3","gravatar_id":"","url":"https://api.github.com/users/skottler","html_url":"https://github.com/skottler","followers_url":"https://api.github.com/users/skottler/followers","following_url":"https://api.github.com/users/skottler/following{/other_user}","gists_url":"https://api.github.com/users/skottler/gists{/gist_id}","starred_url":"https://api.github.com/users/skottler/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/skottler/subscriptions","organizations_url":"https://api.github.com/users/skottler/orgs","repos_url":"https://api.github.com/users/skottler/repos","events_url":"https://api.github.com/users/skottler/events{/privacy}","received_events_url":"https://api.github.com/users/skottler/received_events","type":"User","site_admin":false},"milestone":null,"comments":10,"created_at":"2014-10-07T17:38:20Z","updated_at":"2015-05-15T20:29:08Z","closed_at":"2015-05-11T18:52:39Z","body":"##### Issue Type: \"Feature Idea\"\r\n##### Ansible Version: `ansible 1.7.2`\r\n##### Environment: \r\n* Running from Mac OS X Mavericks, ansible installed via Homebrew\r\n* Administering CentOS 7 on Digital Ocean\r\n\r\n##### Summary:\r\n\r\nDigital Ocean's API now allows selecting your desired image / size / region via \"slugs\", which are just strings that have a 1-to-1 relationship with the desired image_id / size_id / region_id.\r\n\r\n* [Regions](https://developers.digitalocean.com/v1/regions/)\r\n* [Images](https://developers.digitalocean.com/v1/images/)\r\n* [Sizes](https://developers.digitalocean.com/v1/sizes/)\r\n\r\nIt'd be handy to be able to use said slugs in the `digital_ocean` module.\r\n\r\n##### Steps To Reproduce:\r\n\r\n    - hosts: localhost\r\n      connection: local\r\n      tasks:\r\n        - name: Create Digital Ocean droplet size=512Mb image=Centos 7.0 x64 region=New York City 3\r\n          digital_ocean: >\r\n            state=present\r\n            command=droplet\r\n            name=especiallycoherent\r\n            size_id=66\r\n            ssh_key_ids=\"{{ digitalocean.ssh_key.id }}\"\r\n            region_id=nyc3 # or region=nyc3 or region_slug=nyc3 etc.\r\n            image_id=6511101\r\n            unique_name=yes\r\n          register: digitalocean\r\n\r\n\r\n##### Expected Results:\r\n\r\n    ok: [localhost] => {\"changed\": false, \"droplet\": {\"backups_active\": false, \"created_at\": \"2014-10-07T17:36:19Z\", \"id\": 2803097, \"image_id\": 6511101, \"ip_address\": \"123.45.67.89\", \"locked\": false, \"name\": \"awesomebox\", \"private_ip_address\": null, \"region_id\": 8, \"size_id\": 66, \"status\": \"active\"}}\r\n\r\n##### Actual Results:\r\n\r\n    ValueError: invalid literal for int() with base 10: 'nyc3'"},"comment":{"url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/comments/102519286","html_url":"https://github.com/ansible/ansible-modules-core/issues/157#issuecomment-102519286","issue_url":"https://api.github.com/repos/ansible/ansible-modules-core/issues/157","id":102519286,"user":{"login":"bcoca","id":836171,"avatar_url":"https://avatars.githubusercontent.com/u/836171?v=3","gravatar_id":"","url":"https://api.github.com/users/bcoca","html_url":"https://github.com/bcoca","followers_url":"https://api.github.com/users/bcoca/followers","following_url":"https://api.github.com/users/bcoca/following{/other_user}","gists_url":"https://api.github.com/users/bcoca/gists{/gist_id}","starred_url":"https://api.github.com/users/bcoca/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bcoca/subscriptions","organizations_url":"https://api.github.com/users/bcoca/orgs","repos_url":"https://api.github.com/users/bcoca/repos","events_url":"https://api.github.com/users/bcoca/events{/privacy}","received_events_url":"https://api.github.com/users/bcoca/received_events","type":"User","site_admin":false},"created_at":"2015-05-15T20:29:08Z","updated_at":"2015-05-15T20:29:08Z","body":"actually docs are from current devel, we are working on splitting into devel and 'last stable'.\r\n\r\ndocs are not updated automatically, specially for modules, it requires 2 steps: 1 update refs in main repo, issue a 'production docs rebiuld' which we tend to do every week."}}