diff options
author | Vincent Ambo <mail@tazj.in> | 2019-09-02T16·17+0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-02T16·17+0100 |
commit | 4bd6d528008c6a8a7357a2c40013931800582252 (patch) | |
tree | 9f08f325282eafc2ca4fa107bd73ccd53f1aae45 | |
parent | 5e9b91a6d208d1db546afdd4aac7e63de938ad9d (diff) | |
parent | 86d8c748a79de30d9bd4c4fdcec46d0e79ae5e6a (diff) |
Merge pull request #1 from tazjin/feat/travis-ci r/72
Add Travis CI configuration
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | .travis.yml | 10 | ||||
-rw-r--r-- | README.md | 15 | ||||
-rw-r--r-- | default.nix | 2 | ||||
-rw-r--r-- | services/tazblog/default.nix | 6 |
5 files changed, 30 insertions, 4 deletions
diff --git a/.gitignore b/.gitignore index 520d4b582e5d..3afe2d6acf13 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ bazel-* # Ignore Nix result symlinks result +result-* diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 000000000000..eace0ae15bc6 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,10 @@ +language: nix +env: + - NIX_PATH="nixpkgs=${TRAVIS_BUILD_DIR}" +before_script: + - nix-env -f '<nixpkgs>' -iA cachix + - cachix use tazjin +script: + # All of my own tools are under the top-level 'tazjin' attribute + # set, this command will build all of them. + - nix-build -A tazjin | cachix push tazjin diff --git a/README.md b/README.md new file mode 100644 index 000000000000..dc4b7f79e65f --- /dev/null +++ b/README.md @@ -0,0 +1,15 @@ +depot +===== + +[![Build Status](https://travis-ci.org/tazjin/depot.svg?branch=master)](https://travis-ci.org/tazjin/depot) + +This repository is the [monorepo][] for my personal infrastructure. It is built +using [Nix][] and services are deployed on Google Cloud Platofrm using +[Nixery][]. + +Everything in here is MIT-licensed unless otherwise indicated in a service +subfolder. + +[monorepo]: https://en.wikipedia.org/wiki/Monorepo +[Nix]: https://nixos.org/nix +[Nixery]: https://github.com/google/nixery diff --git a/default.nix b/default.nix index 71ac4c3c6e13..ccb301d68f4e 100644 --- a/default.nix +++ b/default.nix @@ -25,7 +25,7 @@ let localPkgs = self: super: { # Local projects should be added here: tazjin = { - blog = import ./services/tazblog { pkgs = self; }; + blog = self.callPackage ./services/tazblog {}; blog_cli = self.callPackage ./tools/blog_cli {}; gemma = self.callPackage ./services/gemma {}; }; diff --git a/services/tazblog/default.nix b/services/tazblog/default.nix index b1a1f95587bc..fa436b824cad 100644 --- a/services/tazblog/default.nix +++ b/services/tazblog/default.nix @@ -2,10 +2,10 @@ # # tazblog.nix was generated using cabal2nix. -{ pkgs ? import <nixpkgs> {} }: +{ writeShellScriptBin, haskell }: -let tazblog = pkgs.haskell.packages.ghc865.callPackage ./tazblog.nix {}; -in pkgs.writeShellScriptBin "tazblog" '' +let tazblog = haskell.packages.ghc865.callPackage ./tazblog.nix {}; +in writeShellScriptBin "tazblog" '' export PORT=8000 export RESOURCE_DIR=${./static} exec ${tazblog}/bin/tazblog |