{"action":"created","issue":{"url":"https://api.github.com/repos/aws/aws-codedeploy-agent/issues/44","repository_url":"https://api.github.com/repos/aws/aws-codedeploy-agent","labels_url":"https://api.github.com/repos/aws/aws-codedeploy-agent/issues/44/labels{/name}","comments_url":"https://api.github.com/repos/aws/aws-codedeploy-agent/issues/44/comments","events_url":"https://api.github.com/repos/aws/aws-codedeploy-agent/issues/44/events","html_url":"https://github.com/aws/aws-codedeploy-agent/issues/44","id":124133694,"number":44,"title":"Debian package ignores /usr/sbin/policy-rc.d, always starts daemon","user":{"login":"ktheory","id":975,"avatar_url":"https://avatars.githubusercontent.com/u/975?v=3","gravatar_id":"","url":"https://api.github.com/users/ktheory","html_url":"https://github.com/ktheory","followers_url":"https://api.github.com/users/ktheory/followers","following_url":"https://api.github.com/users/ktheory/following{/other_user}","gists_url":"https://api.github.com/users/ktheory/gists{/gist_id}","starred_url":"https://api.github.com/users/ktheory/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ktheory/subscriptions","organizations_url":"https://api.github.com/users/ktheory/orgs","repos_url":"https://api.github.com/users/ktheory/repos","events_url":"https://api.github.com/users/ktheory/events{/privacy}","received_events_url":"https://api.github.com/users/ktheory/received_events","type":"User","site_admin":false},"labels":[{"id":140573663,"url":"https://api.github.com/repos/aws/aws-codedeploy-agent/labels/enhancement","name":"enhancement","color":"84b6eb","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2015-12-28T22:10:37Z","updated_at":"2017-02-09T15:46:18Z","closed_at":null,"body":"When creating a base Ubuntu AMI with the codedeploy agent pre-installed, I'd like to be able to install the codedeploy agent w/out the daemon starting.\n\nAfter installing on the base AMI, I need to manually stop the daemon and clean up log files.\n\nThe idiomatic way to handle whether to start a service during installation is to use [`invoke-rc.d`](https://people.debian.org/~hmh/invokerc.d-policyrc.d-specification.txt).\n\nInstead of invoking `service codedeploy-agent {start,stop}` in `postinst`/`prerm`, use `invoke-rc.d`:\n\n```\n# In postinst:\ninvoke-rc.d codedeploy-agent start\n```\n\nSee the nginx package's postinst script for example.\n\n`invoke-rc.d` runs `/usr/sbin/policy-rc.d` to determine whether a service should be started.\n\nI looked for how to make this change myself in a pull request, but I couldn't figure out how the controls scripts in the deb package is generated from this repo.\n"},"comment":{"url":"https://api.github.com/repos/aws/aws-codedeploy-agent/issues/comments/278680831","html_url":"https://github.com/aws/aws-codedeploy-agent/issues/44#issuecomment-278680831","issue_url":"https://api.github.com/repos/aws/aws-codedeploy-agent/issues/44","id":278680831,"user":{"login":"jinty","id":553369,"avatar_url":"https://avatars.githubusercontent.com/u/553369?v=3","gravatar_id":"","url":"https://api.github.com/users/jinty","html_url":"https://github.com/jinty","followers_url":"https://api.github.com/users/jinty/followers","following_url":"https://api.github.com/users/jinty/following{/other_user}","gists_url":"https://api.github.com/users/jinty/gists{/gist_id}","starred_url":"https://api.github.com/users/jinty/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jinty/subscriptions","organizations_url":"https://api.github.com/users/jinty/orgs","repos_url":"https://api.github.com/users/jinty/repos","events_url":"https://api.github.com/users/jinty/events{/privacy}","received_events_url":"https://api.github.com/users/jinty/received_events","type":"User","site_admin":false},"created_at":"2017-02-09T15:46:18Z","updated_at":"2017-02-09T15:46:18Z","body":"+1 I've also hit this, it is quite irritating. Fortunately unpacking using dpkg-deb and editing the postinst seems to work."}}
{"actor":{"display_login":"jinty"}}