{"action":"created","issue":{"url":"https://api.github.com/repos/lxc/lxd/issues/1363","repository_url":"https://api.github.com/repos/lxc/lxd","labels_url":"https://api.github.com/repos/lxc/lxd/issues/1363/labels{/name}","comments_url":"https://api.github.com/repos/lxc/lxd/issues/1363/comments","events_url":"https://api.github.com/repos/lxc/lxd/issues/1363/events","html_url":"https://github.com/lxc/lxd/issues/1363","id":119167370,"number":1363,"title":"LAN Access: Port Forwarding Plan","user":{"login":"techtonik","id":515889,"avatar_url":"https://avatars.githubusercontent.com/u/515889?v=3","gravatar_id":"","url":"https://api.github.com/users/techtonik","html_url":"https://github.com/techtonik","followers_url":"https://api.github.com/users/techtonik/followers","following_url":"https://api.github.com/users/techtonik/following{/other_user}","gists_url":"https://api.github.com/users/techtonik/gists{/gist_id}","starred_url":"https://api.github.com/users/techtonik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/techtonik/subscriptions","organizations_url":"https://api.github.com/users/techtonik/orgs","repos_url":"https://api.github.com/users/techtonik/repos","events_url":"https://api.github.com/users/techtonik/events{/privacy}","received_events_url":"https://api.github.com/users/techtonik/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":16,"created_at":"2015-11-27T09:57:30Z","updated_at":"2016-08-20T14:28:59Z","closed_at":null,"body":"Reticketed from https://github.com/lxc/lxd/issues/591#issuecomment-99900927\r\n\r\n1. Use `iptables` for adding [commented rules](https://unix.stackexchange.com/questions/245151/firewall-that-allows-to-tag-or-comment-rules-for-easy-filtering/245239#245239) when\r\n\r\n  * [ ] container is started\r\n\r\n2. [Remove commented rule](https://unix.stackexchange.com/questions/245366/find-my-rules-in-iptables/245372#245372) when\r\n\r\n  * [ ] container is stopped\r\n\r\n3. Fail with sane error message if\r\n\r\n  * [ ] port is busy\r\n\r\nRule example:\r\n```\r\niptables -t nat -A PREROUTING -p tcp -i eth0 -d 192.168.1.15 --dport 587 -j DNAT \\\r\n    --to-destination 10.0.3.100:587  -m comment --comment \"LXC (ubuntu1) port forward\"\r\n```\r\nWhich says that all packets arriving to host (192.168.1.15) port 587 should be routed to address:port 10.0.3.100:587\r\n\r\nSo, is that possible?"},"comment":{"url":"https://api.github.com/repos/lxc/lxd/issues/comments/241203118","html_url":"https://github.com/lxc/lxd/issues/1363#issuecomment-241203118","issue_url":"https://api.github.com/repos/lxc/lxd/issues/1363","id":241203118,"user":{"login":"JustinJudd","id":1757801,"avatar_url":"https://avatars.githubusercontent.com/u/1757801?v=3","gravatar_id":"","url":"https://api.github.com/users/JustinJudd","html_url":"https://github.com/JustinJudd","followers_url":"https://api.github.com/users/JustinJudd/followers","following_url":"https://api.github.com/users/JustinJudd/following{/other_user}","gists_url":"https://api.github.com/users/JustinJudd/gists{/gist_id}","starred_url":"https://api.github.com/users/JustinJudd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JustinJudd/subscriptions","organizations_url":"https://api.github.com/users/JustinJudd/orgs","repos_url":"https://api.github.com/users/JustinJudd/repos","events_url":"https://api.github.com/users/JustinJudd/events{/privacy}","received_events_url":"https://api.github.com/users/JustinJudd/received_events","type":"User","site_admin":false},"created_at":"2016-08-20T14:28:59Z","updated_at":"2016-08-20T14:28:59Z","body":"I wrote a tool that can monitor LXD and make changes to IPTable rules as containers come up or down. [https://github.com/JustinJudd/lxd-port-forward](https://github.com/JustinJudd/lxd-port-forward)\r\n\r\nI really love the `lxd teleport` idea to be able to make these changes on lxd remotes and not having to ssh over. In the meantime, I have added daemon and systemd support so it should be really easy to just throw onto an LXD host and add a configuration file and let it go."}}
{"actor":{"display_login":"JustinJudd"}}