{"action":"created","issue":{"url":"https://api.github.com/repos/pwittchen/ydocker/issues/1","repository_url":"https://api.github.com/repos/pwittchen/ydocker","labels_url":"https://api.github.com/repos/pwittchen/ydocker/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/pwittchen/ydocker/issues/1/comments","events_url":"https://api.github.com/repos/pwittchen/ydocker/issues/1/events","html_url":"https://github.com/pwittchen/ydocker/issues/1","id":175351068,"number":1,"title":"add script for downloading the newest version of the suite","user":{"login":"pwittchen","id":695319,"avatar_url":"https://avatars.githubusercontent.com/u/695319?v=3","gravatar_id":"","url":"https://api.github.com/users/pwittchen","html_url":"https://github.com/pwittchen","followers_url":"https://api.github.com/users/pwittchen/followers","following_url":"https://api.github.com/users/pwittchen/following{/other_user}","gists_url":"https://api.github.com/users/pwittchen/gists{/gist_id}","starred_url":"https://api.github.com/users/pwittchen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwittchen/subscriptions","organizations_url":"https://api.github.com/users/pwittchen/orgs","repos_url":"https://api.github.com/users/pwittchen/repos","events_url":"https://api.github.com/users/pwittchen/events{/privacy}","received_events_url":"https://api.github.com/users/pwittchen/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/pwittchen/ydocker/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":{"login":"pwittchen","id":695319,"avatar_url":"https://avatars.githubusercontent.com/u/695319?v=3","gravatar_id":"","url":"https://api.github.com/users/pwittchen","html_url":"https://github.com/pwittchen","followers_url":"https://api.github.com/users/pwittchen/followers","following_url":"https://api.github.com/users/pwittchen/following{/other_user}","gists_url":"https://api.github.com/users/pwittchen/gists{/gist_id}","starred_url":"https://api.github.com/users/pwittchen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwittchen/subscriptions","organizations_url":"https://api.github.com/users/pwittchen/orgs","repos_url":"https://api.github.com/users/pwittchen/repos","events_url":"https://api.github.com/users/pwittchen/events{/privacy}","received_events_url":"https://api.github.com/users/pwittchen/received_events","type":"User","site_admin":false},"assignees":[{"login":"pwittchen","id":695319,"avatar_url":"https://avatars.githubusercontent.com/u/695319?v=3","gravatar_id":"","url":"https://api.github.com/users/pwittchen","html_url":"https://github.com/pwittchen","followers_url":"https://api.github.com/users/pwittchen/followers","following_url":"https://api.github.com/users/pwittchen/following{/other_user}","gists_url":"https://api.github.com/users/pwittchen/gists{/gist_id}","starred_url":"https://api.github.com/users/pwittchen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwittchen/subscriptions","organizations_url":"https://api.github.com/users/pwittchen/orgs","repos_url":"https://api.github.com/users/pwittchen/repos","events_url":"https://api.github.com/users/pwittchen/events{/privacy}","received_events_url":"https://api.github.com/users/pwittchen/received_events","type":"User","site_admin":false}],"milestone":null,"comments":1,"created_at":"2016-09-06T21:02:01Z","updated_at":"2016-09-07T20:22:49Z","closed_at":null,"body":"Acceptance Criteria:\r\n- Artifactory REST API can be used\r\n- We can parametrize script and tell it whether we want to download the newest snapshot or release version\r\n- Script should print output with downloaded version to terminal\r\n- Consider using Python for parsing JSON\r\n- Script should be copied into Docker container by Dockerfile\r\n- Script should be executed inside Dockerfile instead of manual wget command"},"comment":{"url":"https://api.github.com/repos/pwittchen/ydocker/issues/comments/245404960","html_url":"https://github.com/pwittchen/ydocker/issues/1#issuecomment-245404960","issue_url":"https://api.github.com/repos/pwittchen/ydocker/issues/1","id":245404960,"user":{"login":"pwittchen","id":695319,"avatar_url":"https://avatars.githubusercontent.com/u/695319?v=3","gravatar_id":"","url":"https://api.github.com/users/pwittchen","html_url":"https://github.com/pwittchen","followers_url":"https://api.github.com/users/pwittchen/followers","following_url":"https://api.github.com/users/pwittchen/following{/other_user}","gists_url":"https://api.github.com/users/pwittchen/gists{/gist_id}","starred_url":"https://api.github.com/users/pwittchen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwittchen/subscriptions","organizations_url":"https://api.github.com/users/pwittchen/orgs","repos_url":"https://api.github.com/users/pwittchen/repos","events_url":"https://api.github.com/users/pwittchen/events{/privacy}","received_events_url":"https://api.github.com/users/pwittchen/received_events","type":"User","site_admin":false},"created_at":"2016-09-07T20:22:49Z","updated_at":"2016-09-07T20:22:49Z","body":"I figured this out with shell oneliners.\r\n\r\nget url for the latest release of concrete version of suite:\r\n```\r\ncurl -u username@sap.com:password https://repository.hybris.com/api/search/artifact\\?name\\=commerce-suite-6.1.0\\&repos\\=hybris-release | python -mjson.tool | grep zip | tail -1 | awk '{print $2}' | sed -e 's/^\"//' -e 's/\"$//'\r\n```\r\n\r\nget url for the latest release:\r\n```\r\ncurl -u username@sap.com:password https://repository.hybris.com/api/search/artifact\\?name\\=commerce-suite\\&repos\\=hybris-release | python -mjson.tool | grep zip | tail -1 | awk '{print $2}' | sed -e 's/^\"//' -e 's/\"$//'\r\n```\r\nget url for the latest snapshot:\r\n\r\n```\r\ncurl -u username@sap.com:password https://repository.hybris.com/api/search/artifact\\?name\\=commerce-suite\\&repos\\=hybris-snapshot | python -mjson.tool | grep zip | tail -1 | awk '{print $2}' | sed -e 's/^\"//' -e 's/\"$//'\r\n```\r\n\r\nMoreover, we need to install Python in Docker container. I suppose it can be done like this:\r\n\r\n```\r\nRUN apt-get install -y python3.4\r\n```"}}
{"actor":{"display_login":"pwittchen"}}