{"action":"created","issue":{"url":"https://api.github.com/repos/projectatomic/atomic/issues/298","repository_url":"https://api.github.com/repos/projectatomic/atomic","labels_url":"https://api.github.com/repos/projectatomic/atomic/issues/298/labels{/name}","comments_url":"https://api.github.com/repos/projectatomic/atomic/issues/298/comments","events_url":"https://api.github.com/repos/projectatomic/atomic/issues/298/events","html_url":"https://github.com/projectatomic/atomic/issues/298","id":131860962,"number":298,"title":"thoughts on a new SPC mechanism","user":{"login":"cgwalters","id":244096,"avatar_url":"https://avatars.githubusercontent.com/u/244096?v=3","gravatar_id":"","url":"https://api.github.com/users/cgwalters","html_url":"https://github.com/cgwalters","followers_url":"https://api.github.com/users/cgwalters/followers","following_url":"https://api.github.com/users/cgwalters/following{/other_user}","gists_url":"https://api.github.com/users/cgwalters/gists{/gist_id}","starred_url":"https://api.github.com/users/cgwalters/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cgwalters/subscriptions","organizations_url":"https://api.github.com/users/cgwalters/orgs","repos_url":"https://api.github.com/users/cgwalters/repos","events_url":"https://api.github.com/users/cgwalters/events{/privacy}","received_events_url":"https://api.github.com/users/cgwalters/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":23,"created_at":"2016-02-06T14:34:48Z","updated_at":"2016-02-18T18:25:33Z","closed_at":null,"body":" I was talking with Giuseppe who is working on https://github.com/giuseppe/flannel-etcd-containerized\r\nand there were a few things here that can be optimized better.  We were thinking of having `atomic install-spc docker.io/projectatomic/flannel` which would do a `docker fetch | ostree commit`, then we use ostree to check out in `/var/spc/$app.[01]` (basically a  versioned directory).\r\n\r\nWe also know how to generate systemd unit files (possibly from template upstream?)  The unit files would use either runc or systemd-nspawn or whatever.\r\n\r\nThen `atomic upgrade-spc` would know how to do the re-fetch, unpack a new fs root, and restart the systemd unit file pointing to it.\r\n\r\nThe advantages of this over `atomic install/run` are that we're not tied to the Docker daemon, which causes all sorts of pain for SPCs that sometimes (like flannel) want to configure Docker itself.  And we don't need an `UNINSTALL` label because we're properly tracking installed files.\r\n"},"comment":{"url":"https://api.github.com/repos/projectatomic/atomic/issues/comments/185847794","html_url":"https://github.com/projectatomic/atomic/issues/298#issuecomment-185847794","issue_url":"https://api.github.com/repos/projectatomic/atomic/issues/298","id":185847794,"user":{"login":"giuseppe","id":67430,"avatar_url":"https://avatars.githubusercontent.com/u/67430?v=3","gravatar_id":"","url":"https://api.github.com/users/giuseppe","html_url":"https://github.com/giuseppe","followers_url":"https://api.github.com/users/giuseppe/followers","following_url":"https://api.github.com/users/giuseppe/following{/other_user}","gists_url":"https://api.github.com/users/giuseppe/gists{/gist_id}","starred_url":"https://api.github.com/users/giuseppe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/giuseppe/subscriptions","organizations_url":"https://api.github.com/users/giuseppe/orgs","repos_url":"https://api.github.com/users/giuseppe/repos","events_url":"https://api.github.com/users/giuseppe/events{/privacy}","received_events_url":"https://api.github.com/users/giuseppe/received_events","type":"User","site_admin":false},"created_at":"2016-02-18T18:25:33Z","updated_at":"2016-02-18T18:25:33Z","body":"ok thanks, then we can move all the new commands to be an `--spc` option for `install/uninstall/update`.\r\n\r\nThe issue I see with --name is how we track file installed on the host as multiple containers from the same image will copy the same file and uninstall on any container will remove these files.\r\n\r\n@cgwalters: should we drop the feature to copy files from /exports/rootfs to the host and allow only files that we know how to handle like `/exports/service.template` for `/usr/local/lib/systemd/system/$NAME.service` and `/exports/config.json` for the runc configuration?"}}