See this issue.
Docker best practise to Control and configure Docker with systemd.
-
Create
daemon.jsonfile in/etc/docker:{"hosts": ["tcp://0.0.0.0:2375", "unix:///var/run/docker.sock"]}
| ## Example configuration: | |
| # upstream fastcgi_backend { | |
| # # use tcp connection | |
| # # server 127.0.0.1:9000; | |
| # # or socket | |
| # server unix:/var/run/php5-fpm.sock; | |
| # } | |
| # server { | |
| # listen 80; | |
| # server_name mage.dev; |
| # | |
| # views.py | |
| # | |
| class ResumeNew(ProtectedMixin, CreateView): | |
| model = Resume | |
| form_class = ResumeForm | |
| success_url = '/accounts/profile/' | |
| template_name = 'resume/new.html' | |
| def get_initial(self): |
See this issue.
Docker best practise to Control and configure Docker with systemd.
Create daemon.json file in /etc/docker:
{"hosts": ["tcp://0.0.0.0:2375", "unix:///var/run/docker.sock"]}
| cat ~/.ssh/id_rsa.pub | \ | |
| ssh user@192.168.1.25 \ | |
| "sudo mkdir /root/.ssh; sudo tee -a /root/.ssh/authorized_keys" | |
| cats my bublic key | |
| pipes it to ssh | |
| ssh connects to my raspberry as ssh user | |
| on remote uses sudo to create /root/.ssh | |
| then uses sudo with "tee -a" to append stdin (which holds the key from first cat) to /root/.ssh/authorized_keys |