]>
git.e2factory.org Git - e2factory.git/log
Tobias Ulmer [Fri, 15 Feb 2019 11:05:05 +0000 (12:05 +0100)]
e2tool: disable write buffering for debug.log
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 15 Feb 2019 11:03:53 +0000 (12:03 +0100)]
e2: install signal handler and dispose our subprocess
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 15 Feb 2019 10:53:40 +0000 (11:53 +0100)]
e2lib: callcmd: add argument to run command under a pseudo tty
Running under a pseudo tty allows using the TIOCSIG ioctl to terminate
non-user owned processes, in particular setuid programs like e2-su or
sudo.
Various improvements around signal handling during forking, with better
error handling and reporting.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 15 Feb 2019 10:42:08 +0000 (11:42 +0100)]
e2lib: finish: if we received a signal, exit with the signal code
Receiving a signal causes subsequent errors which hide the true cause
for termination. Make sure we always exit with 128 + signalno and let
the user know that above errors were caused by a signal.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 15 Feb 2019 10:38:28 +0000 (11:38 +0100)]
e2lib: interrupt_hook: send interrupt to children
note interrupt_hook() no longer terminates e2factory
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 15 Feb 2019 10:27:04 +0000 (11:27 +0100)]
e2lib: add children_.. functions to track and terminate sub processes
If a child process has an associated pseudo terminal, it's terminated
via TIOCSIG ioctl, otherwise the standard kill() function is used.
Allows us to interrupt root-owned children (eg e2-su, sudo, ...)
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 15 Feb 2019 10:10:45 +0000 (11:10 +0100)]
e2lib: support waitpid WNOHANG with wait(pid, true)
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 13 Feb 2019 19:01:37 +0000 (20:01 +0100)]
Makefile: link against libutil, required by forkpty()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 13 Feb 2019 18:42:37 +0000 (19:42 +0100)]
assrt: pass optional message to assert()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 13 Feb 2019 18:24:56 +0000 (19:24 +0100)]
e2lib: close unused sync pipe ends before reading from child
Otherwise we could end up in a situation where we wait for a faulty
child, but hang reading our own pipe.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 13 Feb 2019 17:50:12 +0000 (18:50 +0100)]
e2lib: handle read EINTR in poll loop
Maybe eio.read() should generally loop on EINTR?
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 13 Feb 2019 17:48:53 +0000 (18:48 +0100)]
e2lib: rename: don't shadow the errno module
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 13 Feb 2019 17:45:36 +0000 (18:45 +0100)]
e2lib: wait: format log message
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 13 Feb 2019 14:11:11 +0000 (15:11 +0100)]
e2lib: handle EINTR in poll() and wait()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 13 Feb 2019 13:55:17 +0000 (14:55 +0100)]
transport: rename file instead of calling mv
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 12 Feb 2019 18:55:07 +0000 (19:55 +0100)]
le2lib: block other signals during signal handler execution
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 12 Feb 2019 18:52:44 +0000 (19:52 +0100)]
le2lib: add a ioctl(TIOCSIG) wrapper function
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 12 Feb 2019 18:24:28 +0000 (19:24 +0100)]
le2lib: add functions to block and unblock signals
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 12 Feb 2019 18:06:05 +0000 (19:06 +0100)]
e2lib: implement forkpty
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 11 Feb 2019 19:11:17 +0000 (20:11 +0100)]
eio: log pipe file descriptors
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 11 Feb 2019 18:00:14 +0000 (19:00 +0100)]
le2lib: poll: provide information about POLLERR/POLLHUP/POLLNVAL
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 11 Feb 2019 17:58:01 +0000 (18:58 +0100)]
le2lib: return errno value from poll
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 11 Feb 2019 17:57:17 +0000 (18:57 +0100)]
le2lib: return errno value from waitpid
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 11 Feb 2019 17:56:05 +0000 (18:56 +0100)]
le2lib: stop calling fflush in the fork wrapper
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 11 Feb 2019 17:48:54 +0000 (18:48 +0100)]
eio: use luaL_error
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 11 Feb 2019 17:47:34 +0000 (18:47 +0100)]
eio: add fflush()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 25 Jan 2019 16:11:58 +0000 (17:11 +0100)]
e2lib: if logf() format fails, abort with helpful message
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 9 Jan 2019 12:21:51 +0000 (13:21 +0100)]
tools: fix undeclared variable in error message
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 20 Nov 2018 18:56:46 +0000 (19:56 +0100)]
files: fix collect project whitespace handling in file names
This closes bz#239.
Also fixes a rare issue with the copying of files into an existing
directory.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 19 Nov 2018 17:00:41 +0000 (18:00 +0100)]
e2tool: open debug.log after loading e2.conf
Makes debug.log respect config.log.logrotate.
Closes bz#236.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 12 Nov 2018 18:08:12 +0000 (19:08 +0100)]
lock: provide instructions to fix a locked chroot
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 9 Nov 2018 16:28:17 +0000 (17:28 +0100)]
generic_git: document git_remote_add() and improve remote handling
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 9 Nov 2018 16:22:44 +0000 (17:22 +0100)]
generic_git: add a few helpers for formatting refs
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 25 Oct 2018 13:19:51 +0000 (15:19 +0200)]
files: add support for .tbz2 archives
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 18 Sep 2018 17:55:01 +0000 (19:55 +0200)]
fetch-project: enforce mutual exclusivness of --tag and --branch
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 18 Sep 2018 17:36:17 +0000 (19:36 +0200)]
fetch-project: fix detached HEAD status when using --branch
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 7 Sep 2018 15:20:22 +0000 (17:20 +0200)]
e2-new-source: load project after option handling
Tobias Ulmer [Fri, 7 Sep 2018 15:17:56 +0000 (17:17 +0200)]
generic_git: documentation
Tobias Ulmer [Fri, 7 Sep 2018 15:14:07 +0000 (17:14 +0200)]
e2build: display longer more of the scratch buildid
Tobias Ulmer [Fri, 7 Sep 2018 14:10:24 +0000 (16:10 +0200)]
collect_project: in wc-mode, return a scratch buildid
Due to hashing the dependant results of a cp result, the scratch buildid
status was dropped from the buildid. Aside from an unlikely hash collision,
this does not affect other build modes, but is of course not correct.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 22 Jan 2018 17:29:26 +0000 (18:29 +0100)]
policy: document handle_commandline_options
Tobias Ulmer [Mon, 15 Jan 2018 17:49:23 +0000 (18:49 +0100)]
Unify git refs formatting
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 11 Jan 2018 15:03:43 +0000 (16:03 +0100)]
generic_git: turn errors into assertion
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 22 Dec 2017 15:03:38 +0000 (16:03 +0100)]
e2lib: fix locate_project_root
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 21 Dec 2017 19:33:37 +0000 (20:33 +0100)]
lock: log errors on cleanup, improve
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 21 Dec 2017 19:31:56 +0000 (20:31 +0100)]
err: add tostring() method
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 21 Dec 2017 19:30:56 +0000 (20:30 +0100)]
e2lib: don't close debuglogfile early, improve performance
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 21 Dec 2017 15:24:18 +0000 (16:24 +0100)]
e2build: check for chroot removal, add error message for common issue
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 21 Dec 2017 15:21:53 +0000 (16:21 +0100)]
e2build: clarify creation of directories
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 21 Dec 2017 14:28:20 +0000 (15:28 +0100)]
e2build: ouch, repair error handling in helper_chroot_remove()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 20 Dec 2017 18:03:13 +0000 (19:03 +0100)]
Improve robustness of signal handling
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 20 Dec 2017 17:38:38 +0000 (18:38 +0100)]
e2lib: don't call chdir in rmtempdirs
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 20 Dec 2017 13:30:00 +0000 (14:30 +0100)]
eio: luaL_argerror never returns, but it helps gcc warnings
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 23 Nov 2017 14:56:08 +0000 (15:56 +0100)]
console: set stderr to unbuffered
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 23 Nov 2017 14:35:03 +0000 (15:35 +0100)]
e2build: use result_build_set to skip build steps
Remove return_flags.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 16 Nov 2017 16:37:56 +0000 (17:37 +0100)]
Introduce build_set and result_build_set.
A build set contains a result build sets for each result we want to
build. The result build set contains all configurable settings, modes,
etc. on a per result basis.
This change disentangles all build specific parameters from the static
project configuration.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 14 Nov 2017 15:22:13 +0000 (16:22 +0100)]
result: split build_config() into builtin_env()
Builtin env requires a BuildID, which in turn requires a fully set up
result with build modes etc. just to figure out the temporary directory.
Thus it makes sense to split build_config() into two methods operations,
with only builtin_env() requiring full setup work.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 14 Nov 2017 13:19:41 +0000 (14:19 +0100)]
e2build: fix ldoc tag
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 14 Nov 2017 13:02:49 +0000 (14:02 +0100)]
err: fix ldoc tags
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 3 Nov 2017 18:13:26 +0000 (19:13 +0100)]
e2tool: remove unused print_selection and selected marker
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 2 Nov 2017 19:25:37 +0000 (20:25 +0100)]
move build mode and settings into the build process
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 27 Oct 2017 17:00:39 +0000 (19:00 +0200)]
e2tool: false is a valid value in settings
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 27 Oct 2017 16:24:06 +0000 (18:24 +0200)]
e2tool: remove select_results()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 8 Sep 2017 11:26:26 +0000 (13:26 +0200)]
e2build: clear up confusion between build mode and process mode
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 5 Sep 2017 15:01:34 +0000 (17:01 +0200)]
e2lib: make use of errcode in mkdir()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 5 Sep 2017 14:54:12 +0000 (16:54 +0200)]
e2lib: in mkdir() use same parse_mode argument
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 5 Sep 2017 14:44:11 +0000 (16:44 +0200)]
errno: register errno constants as errcodes
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 5 Sep 2017 14:42:50 +0000 (16:42 +0200)]
err: attach meaningful codes to error objects
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 24 Jul 2017 13:33:25 +0000 (15:33 +0200)]
e2project: introduce a class for the local project
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 28 Jun 2017 17:02:38 +0000 (19:02 +0200)]
err: improve documentation
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 28 Jun 2017 16:33:08 +0000 (18:33 +0200)]
le2lib: return error if fflush before fork fails
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 28 Jun 2017 15:04:10 +0000 (17:04 +0200)]
cache: export file_in_cache()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 4 Jul 2017 13:32:13 +0000 (15:32 +0200)]
generic_git: allow passing workdir to git()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 25 Jun 2018 18:08:25 +0000 (20:08 +0200)]
Add optional sudo support to e2factory
Once sudo is enable, e2-su-2.2 suid permissions can be removed and set
to 755.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 7 Dec 2018 16:06:03 +0000 (17:06 +0100)]
create next changelog entry
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 7 Dec 2018 16:06:03 +0000 (17:06 +0100)]
release e2factory-2.3.17p0
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 7 Dec 2018 16:05:08 +0000 (17:05 +0100)]
update changelog
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 7 Jun 2018 19:24:46 +0000 (21:24 +0200)]
git: wait for pipe children in any order
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 31 May 2018 15:01:50 +0000 (17:01 +0200)]
tools: extend for enable
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 25 May 2018 16:44:19 +0000 (18:44 +0200)]
e2-build: allow --wc-mode foo,bar and add warning
When specifying multiple build modes, warn if there is a default
selected result. It may or may not be what you want.
Add field splitting to build-mode options, currently , and whitespace
are supported.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 22 May 2017 17:00:05 +0000 (19:00 +0200)]
generic_git: fix error handling
found by Anton Hillebrand <ahille@emlix.com>
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 16 May 2017 10:29:57 +0000 (12:29 +0200)]
err: stop evaluation of debug.traceback() every time
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 15 May 2017 14:02:04 +0000 (16:02 +0200)]
le2lib: remove do_parse_mode()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Anton Hillebrand [Thu, 11 May 2017 10:02:47 +0000 (12:02 +0200)]
Moved parse_mode code from c to lua.
Signed-off-by: Anton Hillebrand <ahille@emlix.com>
Tobias Ulmer [Wed, 3 May 2017 17:01:45 +0000 (19:01 +0200)]
transport: remove duplicate comment and rmtempfile call
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 3 May 2017 15:06:33 +0000 (17:06 +0200)]
e2lib: implement rename(), use in rotate_log()
This makes it independent of the "mv" command, allowing to open and
rotate the log file before the tools module is initialized.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 3 May 2017 15:05:11 +0000 (17:05 +0200)]
le2lib: add implementation of rename(2)
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 10 Mar 2017 19:13:58 +0000 (20:13 +0100)]
digest: allow writing SHA256 digests
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 10 Mar 2017 17:29:44 +0000 (18:29 +0100)]
e2-build: check for duplicate results in build mode arguments
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 25 Apr 2018 13:05:42 +0000 (15:05 +0200)]
add buildid logging to help with debugging
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 24 Apr 2018 12:58:32 +0000 (14:58 +0200)]
e2lib: fix e2lib.wait() for signaled process
wait() returned 0 for a signaled process, expecting the caller to
check the third argument for a signal code.
Most call sites do not observe the signal argument, leading to
"successful" execution of a crashing process.
wait() will now return the exit code or signal + 128 in the first
argument. This is in line with various shells.
Also improve debug logging around wait() and callcmd().
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 9 Mar 2017 14:40:31 +0000 (15:40 +0100)]
create next changelog entry
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 9 Mar 2017 14:40:31 +0000 (15:40 +0100)]
release e2factory-2.3.17
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 8 Mar 2017 16:46:29 +0000 (17:46 +0100)]
correct LDoc comments
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Wed, 8 Mar 2017 14:25:18 +0000 (15:25 +0100)]
e2-build: allow a mix of result build modi on the command line
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Tue, 7 Mar 2017 16:00:27 +0000 (17:00 +0100)]
move less interesting messages to log level 4
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Mon, 6 Mar 2017 19:13:53 +0000 (20:13 +0100)]
remove set_licences()/get_licences()
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 3 Mar 2017 17:49:35 +0000 (18:49 +0100)]
files: fix sub-licences default assignment
During the initialization of file entries, new licences were added to
the "outer" file licences list.
This lead to file entries without a licences list getting additional
licence entries that shouldn't have been there.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Fri, 3 Mar 2017 17:35:40 +0000 (18:35 +0100)]
source: add licences() method just like file_class
Saves a lot of string list copying that's better done in an explicit
fashion. get_licences()/set_licences() stay until all extensions are
updated.
Signed-off-by: Tobias Ulmer <tu@emlix.com>
Tobias Ulmer [Thu, 2 Mar 2017 16:14:05 +0000 (17:14 +0100)]
ls-project: add --unused option
Shows all unused results, sources, licences and chroot groups,
respecting result selection on the command line.
Signed-off-by: Tobias Ulmer <tu@emlix.com>