1
0
mirror of /repos/baseimage-docker.git synced 2025-12-30 08:01:31 +01:00

25 Commits

Author SHA1 Message Date
mephi42
669435158f my_init: use stderr for all logs
Useful when you want to run tar within the container
and pipe the archive to host.
2014-07-02 19:12:42 -04:00
Hongli Lai
d0e63da07b Merge pull request #86 from imanel/patch-2
Don't write HOME env variable
2014-06-20 13:45:36 +02:00
Bernard Potocki
2beb0e253e Change break to continue 2014-06-20 12:38:17 +02:00
Paul Annesley
3019bbf09b my_init: runsvdir no longer redirects stderr to proctitle.
As described at http://smarden.org/runit/runsvdir.8.html passing a log
option to runsvdir causes stderr to be redirected to the proctitle.

That prevents stderr from reaching docker logs, which is a big problem.
2014-06-18 09:38:52 -07:00
Bernard Potocki
18a7fe26ec Add USER, GROUP, UID, GID and SHELL to restricted env variables 2014-06-18 17:29:02 +02:00
Hongli Lai (Phusion)
5806f51ea3
Fixed various process waiting issues in my_init.
Closes GH-27. Closes GH-82. Closes GH-83.
Thanks to André Luiz dos Santos and Paul Annesley.
2014-06-17 14:35:05 +02:00
Bernard Potocki
5b403fe06c Don't write HOME env variable
Loading HOME variable breaks multi-user container (i.e. logging as postgres user) if you try to load variables via `/etc/container_environment.sh`.
2014-06-02 15:03:49 +02:00
Hongli Lai (Phusion)
af11b5e7b4 Early in the my_init initialization process, do not overwrite already-defined environment variables by the ones in /etc/container_environment.
Closes GH-52.
2014-05-12 16:14:47 +02:00
Santiago M. Mola
90ff4682df Migrate to Python 3
Ubuntu Trusty ships Python 3 by default, but not Python 2. Older versions already ship Python 3, so this change should be safe.
2014-05-10 12:28:23 +00:00
Stuart Campbell
5e2ee3838d Trim trailing newlines from file-based envs
Many editors add a trailing newline to files. This can result in
slightly unexpected values for environment variables read from
/etc/container_environment.
2014-04-03 00:13:09 +11:00
Hongli Lai (Phusion)
8f9eefa1f6
Correctly pass child process' exit status to sys.exit(). Closes GH-45 2014-03-28 10:23:25 +01:00
Hongli Lai (Phusion)
1684aa1448
Fix my_init not properly forcing Runit to shut down if Runit appears to refuse to respond to SIGTERM. 2014-02-25 22:49:34 +01:00
Hongli Lai (Phusion)
367cddb201
Fix a regression in my_init which causes it to delete environment variables passed from Docker. 2014-02-25 22:08:37 +01:00
Hongli Lai (Phusion)
300adc0bf2
Store environment variables in a file, and allow init scripts to change environment variables.
Closes GH-23.
2014-02-25 12:47:02 +01:00
Hongli Lai (Phusion)
139bc7b81e Merge branch 'feature/16' of https://github.com/thomasleveil/baseimage-docker into thomasleveil-feature/16 2014-02-25 10:30:30 +01:00
Hongli Lai
3d5a46482f Merge pull request #20 from thomasleveil/fix/failed-shutdown-msg
Fix failed shutdown message not displaying process name and PID
2014-02-24 13:23:04 +01:00
Thomas LÉVEIL
55efefa51b fix log not showing messages sent to stdout by my_init 2014-02-22 17:16:55 +01:00
Thomas LÉVEIL
1443856c34 fix failed shutdown message not displaying process name and PID 2014-02-22 16:36:41 +01:00
Thomas LÉVEIL
bf35ff2bf1 allow to install the insecure key with the new --enable-insecure-key option
fix #16
2014-02-22 16:30:08 +01:00
Hongli Lai (Phusion)
b6dac86e04 Improve the init system: support skipping startup files and running a custom main command 2014-02-15 12:11:48 +01:00
Hongli Lai (Phusion)
c22f8804ad Correctly reap child processes that are adopted during invocation of init scripts. 2014-02-13 15:37:32 +01:00
Matt Olson
892dcc7ca4 Bypass runsvdir-start in order to preserve env
runsvdir-start clears the environment, which wipes out any
environment variables passed in when the container starts.
This patch bypasses runsvdir-start and calls runsvdir directly,
preserving the current environment.
2014-02-05 11:52:48 -08:00
Hongli Lai (Phusion)
62859010cb
Allow running scripts during startup. 2014-01-31 15:44:50 +01:00
Hongli Lai (Phusion)
99306bcfcd
Correctly handle Docker shutdown.
When a container is stopped with 'docker stop', SIGTERM is sent to the
init process. Unfortunately neither bash nor runit-init handle that correctly,
so we write our own init system in Python that also waits for all services to
shutdown.
2013-11-12 22:36:55 +01:00
Hongli Lai (Phusion)
9661f84da9
Initial commit 2013-11-12 11:39:25 +01:00