Coder Social home page Coder Social logo

docker-tools's Introduction

Docker tools

Tools to easily get going with your docker-container. Start, stop, restart, build or execute (!) a command on your docker-container as easy as 1 2 3.

Installation

Requirements

Initialization

Start with cloning this repository to your local machine.

git clone https://github.com/LowieHuyghe/docker-tools.git

Configuration

  1. Make a copy of config.example.sh and rename it to config.sh.
  2. Change the configuration to your needs.
  3. Read Usage
  4. Enjoy!

Pro-tip

These script were mainly meant to be used with aliases so you can setup your docker-container as easy as 123.

alias mydocker-start="~/Path/to/start.sh"

Add these to the startup script of your favorite shell and you're all set.

nano ~/.bashrc

Usage

start.sh

Used to start the docker-container. It will automatically check your Viscosity-connection (when configured) and make sure the dns-settings are correct inside docker (when configured)

./start.sh

exec.sh

Used to run a command or a script-file inside the docker-container.

./exec.sh #opens shell on docker-container
./exec.sh echo something
./exec.sh "echo something && echo something else"
./exec.sh somefile.sh

stop.sh

Used to stop the docker-container. It also removes the cached docker-container (not the docker-image) to make sure that after a rebuild it uses the newly created docker-image.

./stop.sh

restart.sh

Used to start and stop the docker-container.

./restart.sh

build.sh

Used to (re)build the docker-image.

./build.sh

kill.sh

Used to stop the docker-machine. Forced stopping is optional.

./kill.sh
./kill.sh -f #Force stop the virtual machine.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.