Commit Graph

30 Commits

Author SHA1 Message Date
Thomas Orozco 325bf78674 Include pre-processed license in repo
Also adding a test in run_build.sh to ensure that the pre-processed
license is always up to date with the actual license file.

To recreate: `xxd -i LICENSE > src/license.h`
2016-11-17 20:20:58 +01:00
Thomas Orozco b67a024460 Rename NO_ARGS to MINIMAL 2016-11-04 18:06:25 +01:00
Michael Crosby 51df7df854 Handle execve exit status
This changes the execve exit status for the child process to be inline
with standard exit status codes for common execve failures.

I don't think this breaks any backwards compat with existing tini users
because it is still returning a non zero exit status but with correct
codes providing more information why it failed.
2016-11-04 13:25:14 +01:00
Thomas Orozco b3a2ba638e NO_ARGS: White labelling
- Don't mention options that don't exist in Usage.
- Don't include a log prefix when NO_ARGS is set.
- Turn up the default verbosity to FATAL when NO_ARGS is set.
- Expose verbosity via an ENV var for debugging.
2016-11-04 13:22:41 +01:00
Thomas Orozco c9ff1b6917 Add a --version flag
See: https://github.com/krallin/tini/issues/55
2016-11-03 19:32:59 +01:00
Thomas Orozco 480fed14ae Optionally disable arg parsing (-DNO_ARGS=ON) 2016-11-02 18:05:12 +01:00
Thomas Orozco 6131b96251 Skip packages on ARM
Right now, the packages are hard-coded to report the amd64 architecture.
I'm not sure they'll be used or needed, so for now let's ignore and skip
them.
2016-10-30 15:55:56 +01:00
Thomas Orozco c8cc8274b8 ARM Cross Builds
- Upgrade to Trusty for the ARM 64 toolchain.
- Cross-compile to ARM.
- Label binaries and packages when releasing.
2016-10-30 15:55:56 +01:00
Jorge Marin df9dbc1055 Replace GPG key short id for full fingerprint (#48)
Prevent dead beef attack
2016-09-01 19:31:55 +02:00
Thomas Orozco be71d120e7 Embed license and add -l flag to show it
This adds 1k of weight to the resulting binary, which is reasonable
(it's less than 5% for the smaller non-static binary), but alleviates
legitimate user concern that the license requires being included when
Tini is redistributed.
2016-08-10 08:50:47 +02:00
Thomas Orozco 2eeac4cd60 Don't attempt to sign without GPG_PASSPHRASE
This ensures PRs can build even though GPG_PASSPHRASE is missing.
2016-08-10 08:49:56 +02:00
Thomas Orozco 44b5675f0e Sign `tini` and `tini-static` binaries
The GPG signing subkey and passphrase are respectively provided through
a Travis encrypted file and a Travis encrypted environment variable.

Signing is only done if there is a signing key present when the build is
complete (so as to not fail when e.g. building a PR that doesn't have
encrypted files available).
2016-01-26 21:56:43 -05:00
Thomas Orozco 2b5b0ecb6e Add tests for hardening in CI script
This ensures that _FORTIFY_SOURCE is actually used!
2015-11-05 11:19:36 +01:00
Thomas Orozco a0bf435d2f Test that Tini restores signal configuration
Tini ignores certain signals, and blocks others, but in both cases
we restore them before executing the child process.

Add tests to ensure that we actually do that!
2015-10-31 15:31:57 +01:00
Thomas Orozco 40d313000c Add tests for passing tty to child process group 2015-10-31 15:31:57 +01:00
Thomas Orozco 672c86cd36 Add smoke test in ci build 2015-09-06 15:50:24 +02:00
Thomas Orozco 4b3075a11d Add tests for subreaper-less Tini
If we're going to make subreaper support an option, we should ensure
that running without subreaper support also works.
2015-09-06 15:29:11 +02:00
Thomas Orozco 1dc66f81eb Accelerate local builds by caching psutil, prctl 2015-09-01 21:17:10 +02:00
Thomas Orozco 376d186b2e Set default verbosity level to 1
This means warnings always show warnings, which is the right thing to do
considering the 2 warnings we show are actually for important
information.
2015-09-01 21:17:10 +02:00
Thomas Orozco bcb8a4b870 Allow users to enable sub-reaping
This allows users that don't control PID 1 in their container to still
use Tini to reap zombies.
2015-09-01 21:17:10 +02:00
Thomas Orozco 1a863f8366 Run some functional tests in ci/run_build.sh
Using the child subreaper mechanism, we can actually run
tests inside the CI environment without depending on Docker.

While this does not replace the existing tests, it allows
at least some functional coverage within CI.
2015-07-05 14:25:21 +02:00
Tianon Gravi f2229f937e Bring back tini-static! 🎉
This allows the use of `tini` within even more minimal environments (such as images that are `FROM scratch` with a single application binary `COPY`'d in).
2015-06-26 21:43:53 +02:00
Thomas Orozco f9dd36c1c0 Don't fail build if logging contents fails 2015-05-05 22:02:19 +02:00
Thomas Orozco 22e58b4c59 Log contents of packages for visual audit 2015-05-05 21:21:39 +02:00
Thomas Orozco 75f674edb1 Use absolute path to load stub rpmbuild
On Travis, Cmake does not run from the same directory as in our local
build environment. We need to ensure that PATH contains absolute paths
so that Cmake can find our stub rpmbuild.
2015-05-05 21:14:56 +02:00
Thomas Orozco 12749881e0 Workaround to ensure compatibility with older CMake
Travis uses Ubuntu Precise, which has CMake 3.8. That version does not
have support for excluding /usr and /usr/bin from the %files% list
(which results in a package that conflicts with the filesystem package
and fails to install).

This commit:

+ Builds on Precise instead of Trusty
+ Adds install tests
2015-05-04 22:24:01 +02:00
Thomas Orozco a1d6372ef6 Generate DEB and RPM packages 2015-05-04 20:59:17 +02:00
Thomas Orozco 178f46aa01 Convert to out-of-tree builds 2015-03-15 18:46:13 +01:00
Thomas Orozco 699c3aadf2 Remove the static build for now
The static build doesn't build with clang, and its usefulness is dubious
for the time being considering the only requirement is glibc.
2015-03-15 16:56:12 +01:00
Thomas Orozco ec36a858db Add travis / ci build script 2015-03-15 16:12:45 +01:00