aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--.travis.yml21
-rw-r--r--custom.nix (renamed from dhall-1.34.0.nix)6
-rw-r--r--default.nix11
-rwxr-xr-xtests/kong.py2
4 files changed, 25 insertions, 15 deletions
diff --git a/.travis.yml b/.travis.yml
index 6c68012..6c36f0a 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,20 +1,17 @@
1--- 1---
2language: nix 2language: nix
3nix: 2.3.1 3nix: 2.3.4
4env:
5 - CUSTOM_NIX_PATH=nixpkgs=channel:nixos-20.09
4 6
5 7# Travis nix integration will install nix AFTER the environment variables are set
6# Use the new container infrastructure 8# and the nix installer will overide NIX_PATH variable thus we need to re-export it
7sudo: false 9before_install:
10 - export NIX_PATH="$CUSTOM_NIX_PATH"
8 11
9install: 12install:
10 # Update nix channels 13 # Install dependencies
11 - nix-channel --add https://nixos.org/channels/nixpkgs-19.09-darwin nixpkgs 14 - nix-env -i -f ./default.nix
12 - nix-channel --remove nixpkgs-unstable
13 - nix-channel --update
14
15 # Install ansible
16 - nix-env -i python3 ansible ansible-lint
17 - nix-env -if ./dhall-1.34.0.nix
18 15
19 # Check ansible version 16 # Check ansible version
20 - ansible --version 17 - ansible --version
diff --git a/dhall-1.34.0.nix b/custom.nix
index a70d201..f8fe7ce 100644
--- a/dhall-1.34.0.nix
+++ b/custom.nix
@@ -1,7 +1,7 @@
1{ pkgs ? import <nixpkgs> {} }: with pkgs; 1{ pkgs ? import <nixpkgs> {} }: with pkgs;
2 2
3let 3let
4 mkVersion = 4 mkDhallVersion =
5 version: sha256: 5 version: sha256:
6 stdenv.mkDerivation { 6 stdenv.mkDerivation {
7 name = "dhall-${version}"; 7 name = "dhall-${version}";
@@ -19,4 +19,6 @@ let
19 ''; 19 '';
20 }; 20 };
21in 21in
22 mkVersion "1.34.0" "0n64jkgbv7a3cmlv3gxpgc11p9b5w0k9nc0zm9am2pzmp6vm6b4n" 22{
23 dhall = mkDhallVersion "1.34.0" "0n64jkgbv7a3cmlv3gxpgc11p9b5w0k9nc0zm9am2pzmp6vm6b4n";
24}
diff --git a/default.nix b/default.nix
new file mode 100644
index 0000000..6c1756e
--- /dev/null
+++ b/default.nix
@@ -0,0 +1,11 @@
1{ pkgs ? import <nixpkgs> {} }: with pkgs;
2
3 let
4 custom = callPackage ./custom.nix {};
5 in
6{
7 inherit ansible_2_8;
8 inherit (custom)dhall;
9 inherit (python38Packages)
10 ansible-lint;
11}
diff --git a/tests/kong.py b/tests/kong.py
index 32bafb2..4e2df28 100755
--- a/tests/kong.py
+++ b/tests/kong.py
@@ -1,4 +1,4 @@
1#!/usr/bin/env python 1#!/usr/bin/env python3
2 2
3from http.server import HTTPServer, CGIHTTPRequestHandler 3from http.server import HTTPServer, CGIHTTPRequestHandler
4 4