1
0
mirror of https://github.com/ohwgiles/laminar.git synced 2024-10-27 20:34:20 +00:00
Commit Graph

244 Commits

Author SHA1 Message Date
Oliver Giles
40b708c594 UserManual: remove outdated reference to tags 2019-12-25 14:34:17 +02:00
Oliver Giles
b8ab43b508 UserManual: add CLICOLOR_FORCE docs 2019-12-23 07:58:52 +02:00
Oliver Giles
3fde38c6b8 job leader process
Implement a separate process, the "leader", which runs all the
scripts for a job run, instead of directly from the main laminard
process. This makes for a cleaner process tree view, where the
owning job for a given script is clear; also the leader process
acts as a subreaper to clean up any wayward descendent processes.

Resolves #78.
2019-12-23 07:56:37 +02:00
Oliver Giles
304ef797b8 install laminard in usr/sbin not usr/bin
complies with FHS
2019-12-13 11:39:30 +02:00
Oliver Giles
e6f338ceb2 readme: add sentence about contributing
with link to the DCO.

(hopefully) resolves #98
2019-12-13 11:17:31 +02:00
Oliver Giles
0384fc9a0a
Replace nodes/tags with contexts
The nodes/tags system has not been particularly successful, it's not as
intuitive as it could be, and in an attempt to be a single feature to address
many use cases, ends up addressing none of them particularly well.

This commit replaces nodes and tags with contexts.

Each job may define which context(s) the job may be associated with.
Laminar will only pop the job off the waiting queue when it can be assigned
to a context. A context defines an integer number of executors, which
represents how many runs can be simultaneously assigned to it. A context
may provide extra environment variables.

Essentially, a context replaces a node, and tags are gone. You just assign
jobs to contexts directly, and you can use a glob expression. This should be
more intuitive.

For grouping jobs in the WebUI, a separate mechanism called "groups" is provided.
2019-12-13 10:42:22 +02:00
Oliver Giles
a0da7b109e pkg: add build script for centos 8 2019-11-02 11:24:48 +02:00
Oliver Giles
4534cb8627 pkg: mark ~upstream version in centos rpm 2019-11-01 20:36:57 +02:00
Oliver Giles
8cf31fa1c2 debian package: mark /etc/laminar.conf as a config file
This triggers apt's configuration file management system, allowing
the user to choose their locally modified version, the new upstream
version, inspect differences etc; instead of blindly overwriting it.

Resolves #92.
2019-11-01 10:51:39 +02:00
Oliver Giles
4aaa930e17 debian10 pkg script: add missing dependency on libcapnp 2019-11-01 10:26:02 +02:00
Oliver Giles
8a1095cb73 move packaging scripts into pkg directory
This helps avoid confusion with the 'docker' directory. Also restore
the debian9 scripts which may be useful for a while longer, update
the names of the scripts and update the README accordingly.
2019-11-01 10:24:03 +02:00
Oliver Giles
ba472711be refactor: remove run page json type hack
this hack tried to avoid sending unnecessary data to the frontend,
but it was more trouble than it's worth
2019-11-01 07:27:34 +02:00
Oliver Giles
39ca7e86cf replace websockets with sse and refactor
Large refactor that more closely aligns the codebase to the kj async
style, more clearly exposes an interface for functional testing and
removes cruft. There is a slight increase in coupling between the
Laminar and Http/Rpc classes, but this was always an issue, just until
now more obscured by the arbitrary pure virtual LaminarInterface class
(which has been removed in this change) and the previous lumping
together of all the async stuff in the Server class (which is now
more spread around the code according to function).

This change replaces the use of Websockets with Server Side Events
(SSE). They are simpler and more suitable for the publish-style messages
used by Laminar, and typically require less configuration of the
reverse proxy HTTP server.

Use of gmock is also removed, which eases testing in certain envs.

Resolves #90.
2019-10-05 20:06:35 +03:00
Oliver Giles
4a07e24da3 split server into http and rpc parts
this is initial preparation for a larger refactor
2019-09-27 20:50:46 +03:00
Oliver Giles
4614ada1d3 log: use fully qualified namespace ref for __FILE_BASE__
helps prevent conflicts if "using namespace" is used
2019-09-27 10:48:00 +03:00
Oliver Giles
21c097a7a9 resolves #104: fix clang compiler error
provide a local typedef instead of using a pure anonymous struct

also fix inconsistent whitespace
2019-09-27 10:42:01 +03:00
Devon Bagley
b90f49987f resolves #102: example Dockerfile to build laminar docker image
Create example Dockerfile and document its use in the User Manual.

This provides a minimal Alpine Linux based starting point for users who want to build a custom Laminar Docker container.
2019-09-19 09:10:05 +03:00
Oliver Giles
2ee950d1c3 build scripts: debian 10 is now current stable 2019-09-04 09:33:16 +03:00
Stefan Bühler
5d31d4152e fix debian package filename and contained version (#101)
The inner version should be the same as the one in the filename; the
filename pattern is "${name}_${version}_${arch}.deb".

Set the version suffix to avoid conflicts with a future Debian package
and include the Debian version this package was built against.
2019-09-04 09:31:43 +03:00
Oliver Giles
e1fe5697d2 README: add explicit instruction for installing dependencies 2019-08-25 07:48:56 +03:00
Oliver Giles
7b418a546c add uint typedef
Needed for musl
2019-07-04 12:28:33 +03:00
[[sroracle]]
1642899159 test: fix RunTest on systems with single file core utilities (#95)
On systems such as Alpine Linux (with busybox) and Adelie Linux (with
coreutils), the shell core utilities such as pwd, true, false, env, and
yes are all symlinks to a single binary. This single binary relies on
the name of the symlink to determine which command ("applet" in busybox
parlance) to execute. Therefore creating symlinks to these symlinks will
not work since the single binary will only see the top-level symlink and
thus think it is an invalid command.

Instead, generate executable shell scripts that exec into the desired
command. This also allows $PATH based resolution to occur instead of
hard-coding the command paths.

See also issue #94.
2019-05-24 21:27:24 +03:00
Oliver Giles
448d8cfa48 log.h: null-terminate compile-time filename strings 2019-04-17 09:26:45 +03:00
Oliver Giles
21ea5363a9 resolves #89: ignore unknown http query params 2019-04-15 06:54:21 +03:00
Oliver Giles
0c67d4c844 logging: strip full paths from __FILE__ at compile-time 2019-04-11 22:14:26 +03:00
Oliver Giles
bcb8b438f3 laminarc: more explicit return codes 2019-04-11 21:00:00 +03:00
Oliver Giles
a851f19eb3 resolves #85: systemd unit file After=network.target 2019-03-31 08:36:08 +03:00
Oliver Giles
95482c78a5 resolves #80: reverse-proxy with custom base URL
Fix all hrefs and vue routes to correctly operate against the
<base href> tag. Add a configuration parameter to override the
content of the href attribute, and describe its use.
2019-03-29 22:43:16 +03:00
Oliver Giles
210787a352 log endpoint: hint to reverse-proxy not to buffer
As discussed in #88, nginx will buffer the chunked transfer-encoding
unless the proxy_buffering directive is disabled, or the
X-Accel-Buffering header is set to no. Do the latter to reduce
configuration burden on frontend reverse-proxy setups.
2019-03-29 22:40:46 +03:00
Vaclav Valicek
303fe7c6ae resolves #87: Fix archive url: missing slash
Terminate default URL with slash, add slash to custom URL when absent
2019-03-27 09:00:13 +02:00
Oliver Giles
bb81931ce9 regression fix: badge url
badge urls were returning 404 and an exception message since
cec4721e. Fixed by correctly extracting the job name from the
request URL
2019-03-08 08:20:41 +02:00
Oliver Giles
b15166e83b resolves #82: implement /latest endpoint
for run page on webui and archive (via symlink)
2019-02-18 23:06:11 +02:00
Oliver Giles
137f35bdd7 additional fixes for #79: chunked http log
fix a missing js function call that broke log output in the
webui, and replace TextDecoderStream with TextDecoder because
the former isn't supported in Firefox
2019-02-18 23:03:14 +02:00
Oliver Giles
807901c719 additional fixes for #79: chunked http log
use correct sqlite column name
remove redundant code, tidy implementation
2019-02-17 22:51:11 +02:00
Oliver Giles
cec4721e52 resolves #79: serve logs over plain chunked http 2019-02-15 19:05:44 +02:00
Oliver Giles
5c7421c833 minor valgrind fixes 2019-02-15 18:24:36 +02:00
Oliver Giles
31c64980f7 Catch exceptions in websockets and drop the connection 2018-12-30 08:26:58 +02:00
Oliver Giles
c0556b871b resolves #77: exit noisily on ::bind failure 2018-12-14 15:23:57 +02:00
Oliver Giles
fd03993744 resolves #75: CMAKE_INSTALL_PREFIX not always respected 2018-12-14 14:38:33 +02:00
Oliver Giles
243c696a21 resolves #73: script to build Raspbian package 2018-11-30 15:56:22 +02:00
Geraldo Ribeiro
ce52a382f0 Documentation minor fixes 2018-11-06 19:57:09 +02:00
Oliver Giles
cc7d9fa4da minor README tweaks: use https in links and add badge 2018-10-16 20:47:10 +03:00
Oliver Giles
42fc7284cd move conf file and unit file to etc dir 2018-10-16 20:40:10 +03:00
Oliver Giles
fda11a652b Install bash/zsh completions in correct locations 2018-10-16 20:38:48 +03:00
Karel Kočí
fab5cef0ca Add completion scripts for laminarc in zsh and bash 2018-10-16 20:38:48 +03:00
Oliver Giles
77b8c8d601 resolves #69: job scripts as symlinks
Fixes some regressions introduced by the recent refactor
2018-10-14 22:16:42 +03:00
Oliver Giles
7cee824cee resolves #67: laminarc list jobs
Implements the following laminarc commands:
- show-jobs
- show-running
- show-queued
- abort
2018-10-12 17:22:21 +03:00
Oliver Giles
21284731a3 UserManual: remove obsolete reference to locks 2018-10-12 17:20:17 +03:00
Oliver Giles
7c600c679f fix node/tag bugs introduced with fs refactor 2018-10-12 17:01:42 +03:00
Oliver Giles
787f8f1681 badge svg: define root element dimensions
This prevents default 300x150 sizing
2018-10-12 12:56:16 +03:00