Make a docker container start automatically on every reboot - ubuntu (우분투 시작시 도커 컨테이너 자동 시작)

  • Create .service file

    sudo nano /etc/systemd/system/start_docker.service

[Unit]

Description=Start docker container on every start


[Service]

Type=simple

ExecStart=docker start my_container_name


[Install]

WantedBy=multi-user.target


  • Start & enable
    sudo systemctl start start_docker

    sudo systemctl enable start_docker

  • Reboot
    sudo reboot





 참고한 싸이트

댓글

이 블로그의 인기 게시물

sklearn tsne + matplotlib scatter

Implementation of Focal Loss using Pytorch