All Projects → pablo-ruth → go-init

pablo-ruth / go-init

Licence: MIT license
A minimal init system for containers with pre/post hooks

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to go-init

nosystemd.org
Website for arguments against systemd and further resources
Stars: ✭ 49 (+36.11%)
Mutual labels:  init, init-system
init
KISS Linux - Init Framework
Stars: ✭ 85 (+136.11%)
Mutual labels:  init, init-system
InitWare
The InitWare Suite of Middleware allows you to manage services and system resources as logical entities called units. Its main component is a service management ("init") system.
Stars: ✭ 164 (+355.56%)
Mutual labels:  init, init-system
tini
A tiny but valid `init` for containers
Stars: ✭ 7,757 (+21447.22%)
Mutual labels:  init, init-system
InitKit
Neo-InitWare is a modular, cross-platform reimplementation of the systemd init system. It is experimental.
Stars: ✭ 364 (+911.11%)
Mutual labels:  init, init-system
kernel-syslog
📝 Kernel module that can be used as a replacement for syslog, logger or logwrapper
Stars: ✭ 37 (+2.78%)
Mutual labels:  init, init-system
secrets-init
minimalistic init system for containers with AWS/GCP secrets support
Stars: ✭ 114 (+216.67%)
Mutual labels:  init
Ansible Supervisor
Ansible role to set up (the latest or a specific version of) supervisor in Debian-like systems
Stars: ✭ 32 (-11.11%)
Mutual labels:  init
brand.systemd.io
Website with systemd brand assets
Stars: ✭ 12 (-66.67%)
Mutual labels:  init
Construction
👷 The many ways to construct and configure your entity
Stars: ✭ 35 (-2.78%)
Mutual labels:  init
Generate
A new command line tool and developer framework for scaffolding out GitHub projects. Generate offers the robustness and configurability of Yeoman, the expressiveness and simplicity of Slush, and more powerful flow control and composability than either.
Stars: ✭ 238 (+561.11%)
Mutual labels:  init
Runit
Development repository for the Chef Runit Cookbook
Stars: ✭ 101 (+180.56%)
Mutual labels:  init
Dumb Init
A minimal init system for Linux containers
Stars: ✭ 5,372 (+14822.22%)
Mutual labels:  init
Finit
Fast init for Linux systems. Cookies included
Stars: ✭ 293 (+713.89%)
Mutual labels:  init
Minit
minimalist init implementation for containers
Stars: ✭ 45 (+25%)
Mutual labels:  init
Hummingbird
Hummingbird init system for Linux based operating systems.
Stars: ✭ 102 (+183.33%)
Mutual labels:  init
Generate Gh Repo
Generate generator to create a new repository on GitHub.
Stars: ✭ 11 (-69.44%)
Mutual labels:  init
S6
The s6 supervision suite.
Stars: ✭ 452 (+1155.56%)
Mutual labels:  init
Nginx Sysvinit Script
Linux Standard Base compliant SysVinit script for nginx.
Stars: ✭ 66 (+83.33%)
Mutual labels:  init
Rustysd
A service manager that is able to run "traditional" systemd services, written in rust
Stars: ✭ 416 (+1055.56%)
Mutual labels:  init

go-init

No Maintenance Intended Build Status

go-init is a minimal init system with simple lifecycle management heavily inspired by dumb-init.

It is designed to run as the first process (PID 1) inside a container.

It is lightweight (less than 500KB after UPX compression) and statically linked so you don't need to install any dependency.

Download

You can download the latest version on releases page

Why you need an init system

I can't explain it better than Yelp in dumb-init repo, so please read their explanation

Summary:

  • Proper signal forwarding
  • Orphaned zombies reaping

Why another minimal init system

In addition to init problematic, go-init tries to solve another Docker flaw by adding hooks on start and stop of the main process.

If you want to launch a command before the main process of your container and another one after the main process exit, you can't with Docker, see issue 6982

With go-init you can do that with "pre" and "post" hooks.

Usage

one command

$ go-init -main "my_command param1 param2"

pre-start and post-stop hooks

$ go-init -pre "my_pre_command param1" -main "my_command param1 param2" -post "my_post_command param1"

docker

Example of Dockerfile using go-init:

FROM alpine:latest

COPY go-init /bin/go-init

RUN chmod +x /bin/go-init

ENTRYPOINT ["go-init"]

CMD ["-pre", "echo hello world", "-main", "sleep 5", "-post", "echo I finished my sleep bye"]

Build it:

docker build -t go-init-example

Run it:

docker run go-init-example
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].