{"action":"created","issue":{"url":"https://api.github.com/repos/habitat-sh/habitat/issues/4975","repository_url":"https://api.github.com/repos/habitat-sh/habitat","labels_url":"https://api.github.com/repos/habitat-sh/habitat/issues/4975/labels{/name}","comments_url":"https://api.github.com/repos/habitat-sh/habitat/issues/4975/comments","events_url":"https://api.github.com/repos/habitat-sh/habitat/issues/4975/events","html_url":"https://github.com/habitat-sh/habitat/issues/4975","id":316398800,"node_id":"MDU6SXNzdWUzMTYzOTg4MDA=","number":4975,"title":"Supervisor filesystem is insufficiently namespaced when running multiple Supervisors","user":{"login":"christophermaier","id":207178,"node_id":"MDQ6VXNlcjIwNzE3OA==","avatar_url":"https://avatars2.githubusercontent.com/u/207178?v=4","gravatar_id":"","url":"https://api.github.com/users/christophermaier","html_url":"https://github.com/christophermaier","followers_url":"https://api.github.com/users/christophermaier/followers","following_url":"https://api.github.com/users/christophermaier/following{/other_user}","gists_url":"https://api.github.com/users/christophermaier/gists{/gist_id}","starred_url":"https://api.github.com/users/christophermaier/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/christophermaier/subscriptions","organizations_url":"https://api.github.com/users/christophermaier/orgs","repos_url":"https://api.github.com/users/christophermaier/repos","events_url":"https://api.github.com/users/christophermaier/events{/privacy}","received_events_url":"https://api.github.com/users/christophermaier/received_events","type":"User","site_admin":false},"labels":[{"id":621112519,"node_id":"MDU6TGFiZWw2MjExMTI1MTk=","url":"https://api.github.com/repos/habitat-sh/habitat/labels/A-supervisor","name":"A-supervisor","color":"87B09A","default":false},{"id":621117263,"node_id":"MDU6TGFiZWw2MjExMTcyNjM=","url":"https://api.github.com/repos/habitat-sh/habitat/labels/C-bug","name":"C-bug","color":"ff9012","default":false},{"id":621119774,"node_id":"MDU6TGFiZWw2MjExMTk3NzQ=","url":"https://api.github.com/repos/habitat-sh/habitat/labels/E-less-easy","name":"E-less-easy","color":"4296b4","default":false},{"id":621121208,"node_id":"MDU6TGFiZWw2MjExMjEyMDg=","url":"https://api.github.com/repos/habitat-sh/habitat/labels/S-needs-discussion","name":"S-needs-discussion","color":"EB6852","default":false},{"id":859405755,"node_id":"MDU6TGFiZWw4NTk0MDU3NTU=","url":"https://api.github.com/repos/habitat-sh/habitat/labels/V-devx","name":"V-devx","color":"0fb0bf","default":false},{"id":859405758,"node_id":"MDU6TGFiZWw4NTk0MDU3NTg=","url":"https://api.github.com/repos/habitat-sh/habitat/labels/V-sup","name":"V-sup","color":"0fb0bf","default":false}],"state":"open","locked":false,"assignee":{"login":"baumanj","id":5906042,"node_id":"MDQ6VXNlcjU5MDYwNDI=","avatar_url":"https://avatars2.githubusercontent.com/u/5906042?v=4","gravatar_id":"","url":"https://api.github.com/users/baumanj","html_url":"https://github.com/baumanj","followers_url":"https://api.github.com/users/baumanj/followers","following_url":"https://api.github.com/users/baumanj/following{/other_user}","gists_url":"https://api.github.com/users/baumanj/gists{/gist_id}","starred_url":"https://api.github.com/users/baumanj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baumanj/subscriptions","organizations_url":"https://api.github.com/users/baumanj/orgs","repos_url":"https://api.github.com/users/baumanj/repos","events_url":"https://api.github.com/users/baumanj/events{/privacy}","received_events_url":"https://api.github.com/users/baumanj/received_events","type":"User","site_admin":false},"assignees":[{"login":"baumanj","id":5906042,"node_id":"MDQ6VXNlcjU5MDYwNDI=","avatar_url":"https://avatars2.githubusercontent.com/u/5906042?v=4","gravatar_id":"","url":"https://api.github.com/users/baumanj","html_url":"https://github.com/baumanj","followers_url":"https://api.github.com/users/baumanj/followers","following_url":"https://api.github.com/users/baumanj/following{/other_user}","gists_url":"https://api.github.com/users/baumanj/gists{/gist_id}","starred_url":"https://api.github.com/users/baumanj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baumanj/subscriptions","organizations_url":"https://api.github.com/users/baumanj/orgs","repos_url":"https://api.github.com/users/baumanj/repos","events_url":"https://api.github.com/users/baumanj/events{/privacy}","received_events_url":"https://api.github.com/users/baumanj/received_events","type":"User","site_admin":false}],"milestone":null,"comments":2,"created_at":"2018-04-20T20:17:28Z","updated_at":"2018-06-22T14:10:53Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"It is possible to run multiple Supervisors on a single system by specifying the `--override-name=<NAME>` option, which will create a `/hab/sup/<NAME>` directory in which to write Supervisor-specific files (if no `--override-name` option is given, `<NAME>` will be `default`).\r\n\r\nWhile this provides separation for Supervisor-specific files, other operational aspects are not so isolated. All service-related files are written into `/hab/svc/<SERVICE-NAME>`; thus, running the same service on two colocated Supervisors will result in both services using the same service directory, which means they will be reading (and rewriting) the same templated files. Additionally, `user.toml` files suffer from the same issue, being stored in `/hab/user/<SERVICE-NAME>/config/user.toml`. Multiple instances of the same service end up using the exact same `user.toml` file.\r\n\r\nApart from these examples, the entire `/hab/pkgs` hierarchy is shared by all Supervisors running on a host, which introduces the opportunity for services to unexpectedly upgrade when newer versions of a service package are installed, since we run the latest available package that satisfies the given service identifier. \r\n\r\nGranted, many of these scenarios likely only arise in extreme, unrealistic, or contrived situations (I can't imagine wanting to literally run three instances of a service in a leader topology on the same machine outside of a Supervisor testing scenario, for instance). However, these behaviors are unexpected, given the implication that `--override-name` gives around running multiple Supervisor processes on a single machine.\r\n\r\nWe should either address these shortcomings by fully namespacing all directories that Supervisors need throughout the course of their operation, or we should consider removing the ability to run multiple Supervisors on a single host."},"comment":{"url":"https://api.github.com/repos/habitat-sh/habitat/issues/comments/399455771","html_url":"https://github.com/habitat-sh/habitat/issues/4975#issuecomment-399455771","issue_url":"https://api.github.com/repos/habitat-sh/habitat/issues/4975","id":399455771,"node_id":"MDEyOklzc3VlQ29tbWVudDM5OTQ1NTc3MQ==","user":{"login":"baumanj","id":5906042,"node_id":"MDQ6VXNlcjU5MDYwNDI=","avatar_url":"https://avatars2.githubusercontent.com/u/5906042?v=4","gravatar_id":"","url":"https://api.github.com/users/baumanj","html_url":"https://github.com/baumanj","followers_url":"https://api.github.com/users/baumanj/followers","following_url":"https://api.github.com/users/baumanj/following{/other_user}","gists_url":"https://api.github.com/users/baumanj/gists{/gist_id}","starred_url":"https://api.github.com/users/baumanj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/baumanj/subscriptions","organizations_url":"https://api.github.com/users/baumanj/orgs","repos_url":"https://api.github.com/users/baumanj/repos","events_url":"https://api.github.com/users/baumanj/events{/privacy}","received_events_url":"https://api.github.com/users/baumanj/received_events","type":"User","site_admin":false},"created_at":"2018-06-22T14:10:53Z","updated_at":"2018-06-22T14:10:53Z","author_association":"MEMBER","body":"Confirmed valid in v0.57, keeping"}}
{"actor":{"display_login":"baumanj"}}