Commit graph

430 commits

Author SHA1 Message Date
Vincent Ambo
0bc731ee1b feat(build): Add WORKSPACE configuration for Bazel
This sets up Haskell & Nix rules in the workspace.
2019-07-04 11:19:40 +01:00
Vincent Ambo
64275e446e feat(third_party/bazel): Check in rules_nixpkgs from Tweag 2019-07-04 11:18:37 +01:00
Vincent Ambo
f723b8b878 feat(third_party/bazel): Check in rules_haskell from Tweag 2019-07-04 11:18:12 +01:00
Vincent Ambo
2eb1dc26e4 feat(tools): Add symlinks for bazel & stylish-haskell 2019-07-04 11:17:34 +01:00
Vincent Ambo
2b31921c3e fix(nix): Ensure package set is callable with/without args
When instantiating a Nix package via Bazel, the package set is called
with an empty map as the argument. From the Nix REPL or the dispatch
script, however, the package set is called without arguments.

This change adds a catch-all optional argument in the package set
which ensures that both use-cases are supported (similar to what
nixpkgs itself does).
2019-07-04 11:15:59 +01:00
Vincent Ambo
af7cbf64e5 feat(dotenv): Set NIX_PATH for entire workspace 2019-07-04 11:15:31 +01:00
Vincent Ambo
b2f40b6ed8 fix(tools): Ensure dispatch script passes arguments correctly 2019-07-04 11:15:15 +01:00
Vincent Ambo
892493a478 feat(tools): Add dispatcher script to transparently access tools
Initial version of tool provider via Nix. This requires two separate
steps for adding a new tool:

1. New symlink in tools/bin to point at the dispatch script.
2. Mapping of tool to Nix package set attribute in dispatch script.
2019-07-02 16:40:51 +01:00
Vincent Ambo
c31a0b552b feat(git-appraise): Add Nix build configuration 2019-07-02 14:39:49 +01:00
Vincent Ambo
fe642c30f0 feat(third_party): Check in git-appraise 2019-07-02 14:19:12 +01:00
Vincent Ambo
e03f063052 merge(infra): Embed infrastructure configuration into monorepo
This contains DNS and NixOS module configuration.
2019-07-02 12:48:14 +01:00
Vincent Ambo
a131b30514 refactor(infra): Move infrastructure into monorepo structure 2019-07-02 12:48:05 +01:00
Vincent Ambo
915a2f8464 fix(tazblog): Ensure build works with MonadFail changes
This updates some old code that makes assumptions via pattern matching
to instead make assumptions via a Prelude function.

This is known to be safe as it has been running fine for almost a
decade now, but the recent MonadFail changes broke the build.
2019-07-02 12:42:28 +01:00
Vincent Ambo
b51a53c936 chore(build): Add Gemma to package set
Note that this does not actually build right now because Elm has done
a thing again to break the universe and it requires massive changes to
the application to make it work again.
2019-06-29 14:28:41 +01:00
Vincent Ambo
e2951dc9f5 merge(gemma): Integrate Gemma into monorepo 2019-06-29 14:14:35 +01:00
Vincent Ambo
60532a541b refactor(gemma): Move Gemma source into monorepo stucture 2019-06-29 14:13:58 +01:00
Vincent Ambo
545d9a2db9 docs(third_party): Add README 2019-06-29 14:12:38 +01:00
Vincent Ambo
4cefb9256a feat(build): Add top-level package index file 2019-06-29 14:12:24 +01:00
Vincent Ambo
5c3ac08fcf feat(tazblog): Add Nix build configuration 2019-06-29 14:11:56 +01:00
Vincent Ambo
207c6dac0c merge(tazblog): Integrate blog into monorepo 2019-06-29 14:02:28 +01:00
Vincent Ambo
47f2145b5b chore(tazblog): Remove files from ye olde times 2019-06-29 14:01:28 +01:00
Vincent Ambo
85dbb4cc23 chore: Keep project root under MIT license
To comply with Google's open-source patching rules :)
2019-06-28 22:56:48 +01:00
Vincent Ambo
2373c925e1 refactor: Move tazblog into monorepo structure
It's happening!
2019-06-28 22:55:39 +01:00
Vincent Ambo
b681368217 chore: Initialize tazj.in monorepo 2019-06-28 22:50:53 +01:00
Vincent Ambo
1109e449ef chore(dns): Update Github pages IP addresses 2018-05-03 14:40:07 +02:00
Vincent Ambo
880df6560c fix(nix): Fix Gogs SSH access
The Gogs developers got it into their head that trying to write things
to some relative path from the binary location is a sensible thing to
do (spoiler: it's not).

Due to their weird "GOGS_CUSTOM" directory which seems to only
sometimes be configurable by environment variables, the command used
to handle SSH requests failed because it attempted to write logs into
the Nix store.

This works around the issue by hardcoding the log file root path in
the Gogs configuration.
2018-01-03 23:21:57 +01:00
Vincent Ambo
a6a48806c4 feat(nix): Add Gemma example deployment 2018-01-03 23:02:48 +01:00
Vincent Ambo
9464a1dee4 chore: Clean up old Kubernetes configuration 2018-01-03 23:02:48 +01:00
Vincent Ambo
51cbf1e92a feat(tazj.in): Add gemma.tazj.in host 2018-01-03 23:02:48 +01:00
Vincent Ambo
61be253d6b feat(build): Configurable output location
For easier Nix builds!
2018-01-03 22:51:20 +01:00
Vincent Ambo
0d7f845bf5 refactor(build): Use ASDF facility for output naming
Turns out there is an easy-to-use :build-pathname parameter to set the
output binary name. This kills the hack!
2018-01-03 16:54:45 +01:00
Vincent Ambo
96c7bdebd6 fix(tazj.in): Set A-record TTLs back to 300 seconds 2018-01-03 16:29:49 +01:00
Vincent Ambo
98281f3548 feat(nix): Configure oslo.pub redirect correctly 2018-01-03 14:31:38 +01:00
Vincent Ambo
20b26dae3b feat(dns): Import oslo-pub zone to git 2018-01-03 14:21:33 +01:00
Vincent Ambo
41a213054d fix(nix): Correctly configure required kernel modules & VMWare guest 2018-01-02 22:51:31 +01:00
Vincent Ambo
f9641cc1ed refactor(nix): Use disk labels instead of disk UUIDs
Makes configuration portable between VM instances.
2018-01-02 12:08:35 +01:00
Vincent Ambo
a9401f94db feat(nix): Configure Gogs setup 2018-01-02 12:08:23 +01:00
Vincent Ambo
9da69a7962 feat(dns): Move tazblog over to GleSYS machine 2018-01-02 00:56:27 +01:00
Vincent Ambo
aac2c029a4 feat(nix): Configure reverse-proxy for tazblog 2018-01-02 00:55:23 +01:00
Vincent Ambo
a646f94d47 feat(nix): Add initial Tazblog Nix deployment configuration 2018-01-01 23:20:17 +01:00
Vincent Ambo
9368117813 feat(dns): Add Runbox SPF & renew Keybase verification 2018-01-01 23:20:03 +01:00
Vincent Ambo
cc6de0f9c6 feat(nix): Add Docker building configuration 2017-12-31 17:02:56 +01:00
Vincent Ambo
48687f77d2 fix(elm): Use relative URL to access API
Now that Hunchentoot is serving the Elm frontend, Elm needs to connect
to Gemma at a relative path.

Side note: It would be useful if the frontend displayed errors that
happened :sun:
2017-12-31 17:02:13 +01:00
Vincent Ambo
bd3b2782b9 feat(lisp): Correctly set location for static assets in Nix builds
In order to let Hunchentoot serve the static assets from the correct
location, the *static-file-location* parameter is set before image
dumping based on the $out-envvar which is present during the build
process.

This can easily be set manually in the config file if required by a
user.
2017-12-31 15:31:52 +01:00
Vincent Ambo
8703b6102c feat(build): Add initial Nix-based build process
Adds a build script using ASDF's program-op to build an executable out
of the Gemma source code.

In addition a Nix derivation is provided that will both compile the
Elm source and place it in a folder, as well as create the executable.

Currently static file serving does not function as intended.
2017-12-29 16:42:10 +01:00
Vincent Ambo
5579ca7d6c feat(build): Configure ASDF program-op with entrypoint 2017-12-26 13:48:57 +01:00
Vincent Ambo
abe8419b03 docs(README): Update docs with a note about configuration 2017-12-26 11:15:27 +01:00
Vincent Ambo
e50e2acde0 docs: Add example configuration file 2017-12-26 11:13:52 +01:00
Vincent Ambo
4536e65471 feat(lisp): Implement configuration loading
Adds configuration loading from a file located at either
"/etc/gemma/config.lisp" or a path determined via the `GEMMA_CONFIG`
environment variable.

The configuration file can contain any number of deftask forms and a
single config form which determines the location at which Gemma stores
its data and also the port on which it should listen.
2017-12-26 11:13:03 +01:00
Vincent Ambo
db0e74fbd0 fix(lisp): Don't intern symbols for unregistered tasks 2017-12-24 18:05:49 +01:00