Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


How do you docker?
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

How do you docker?

So im being forced to learn docker as im switching off lastpass to bitwarden-rs, seems the only way they offer this project is with docker..
So my question is how do you manage your docker containers and why do you do it that way? I already have a instance ready with debian 10 but not sure if i should use some sort of fleet managment.

Comments

  • yoursunnyyoursunny Member, IPv6 Advocate

    I have a pile of text files documenting how to start each container.
    Then I paste those commands into the SSH console.

    Most docker run commands I use have --cpu 0.3 --memory 512M or similar, so that I don't exceed fair use and don't trigger OOM.
    There's also --restart unless-stopped so that the containers can start themselves after the server reboots.

    I hear fancy setups have a thing called Docker Compose, but I haven't tried that.

    Thanked by 1jugganuts
  • afnafn Member
    edited April 2021

    I personally run few containers on my vps, for 1-3 containers I don't think you need anything fancy, just a docker-compose enable docker service, and use docker run --restart=always or restart:always in compose file.

    Why?
    Cuz it's just easy and simple, I never felt I like I need to make things easier or find any other different way to do things.

    I just launched my container once, and now (luckily) no failures happened so far and It just works.

    But it may depend on your needs, if you need advanced logging and to follow ressources usage or such things maybe you may need some interface like https://shipyard-project.com/ (never used it personally)

    Thanked by 1jugganuts
  • You can always just pull the commands from the Dockerfile and put it on a VPS or into a LXC container.

  • jmgcaguiclajmgcaguicla Member
    edited April 2021

    @yoursunny said:
    I have a pile of text files documenting how to start each container.
    Then I paste those commands into the SSH console.

    Most docker run commands I use have --cpu 0.3 --memory 512M or similar, so that I don't exceed fair use and don't trigger OOM.
    There's also --restart unless-stopped so that the containers can start themselves after the server reboots.

    I hear fancy setups have a thing called Docker Compose, but I haven't tried that.

    Compose files aren't even fancy, those are basically the pile of text files you mention, just structured as a YAML document.

  • Docker compose files are great. Wanted to try portainer but never gotten around to it

  • @caracal said:
    Docker compose files are great. Wanted to try portainer but never gotten around to it

    Portainer is a very good tool as it provides a GUI through web to manage your docker containers, images, networks, volumes etc. You can start, stop, kill, view logs for the containers very easily with Portainer.

  • afnafn Member

    @yoursunny said:
    I have a pile of text files documenting how to start each container.
    Then I paste those commands into the SSH console.

    Most docker run commands I use have --cpu 0.3 --memory 512M or similar, so that I don't exceed fair use and don't trigger OOM.
    There's also --restart unless-stopped so that the containers can start themselves after the server reboots.

    I hear fancy setups have a thing called Docker Compose, but I haven't tried that.

    you just reformat your text files wrt the yaml standard. that is, problem solved you won't even have to open the text files again or copy any commands, you will just have have 1 single command to run whenever you need that container up.

Sign In or Register to comment.