[Pkg-javascript-commits] [node-rai] 01/01: Imported Debian patch 0.1.12-3
Thorsten Alteholz
alteholz at moszumanska.debian.org
Sun Jul 17 13:23:15 UTC 2016
This is an automated email from the git hooks/post-receive script.
alteholz pushed a commit to branch master
in repository node-rai.
commit 6c9734a8860f6cea3e92ff8f4666b12711011f37
Author: Thorsten Alteholz <debian at alteholz.de>
Date: Wed Feb 24 19:21:53 2016 +0100
Imported Debian patch 0.1.12-3
---
debian/changelog | 8 ++++++++
.../001-use-ssl-cert-snakeoil-as-default.patch | 4 ++--
debian/tests/control | 2 +-
debian/tests/require | 24 +++++++++++++++++++++-
4 files changed, 34 insertions(+), 4 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index d87d4d4..4ce1774 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+node-rai (0.1.12-3) unstable; urgency=medium
+
+ * snakeoil stuff is not accessible during tests, so better
+ create own cert stuff
+ * use other default values for key and cert
+
+ -- Thorsten Alteholz <debian at alteholz.de> Wed, 24 Feb 2016 19:21:53 +0100
+
node-rai (0.1.12-2) unstable; urgency=medium
* add 001-use-ssl-cert-snakeoil-as-default.patch to allow CI build
diff --git a/debian/patches/001-use-ssl-cert-snakeoil-as-default.patch b/debian/patches/001-use-ssl-cert-snakeoil-as-default.patch
index f3a7eb9..f46e676 100644
--- a/debian/patches/001-use-ssl-cert-snakeoil-as-default.patch
+++ b/debian/patches/001-use-ssl-cert-snakeoil-as-default.patch
@@ -10,8 +10,8 @@ Index: node-rai/lib/rai.js
var defaultCredentials = {
- key: fs.readFileSync(__dirname+"/../cert/server.key"),
- cert: fs.readFileSync(__dirname+"/../cert/server.crt")
-+ key: fs.readFileSync("/etc/ssl/private/ssl-cert-snakeoil.key"),
-+ cert: fs.readFileSync("/etc/ssl/certs/ssl-cert-snakeoil.pem")
++ key: fs.readFileSync("/etc/node-rai/cert/test-rai.key"),
++ cert: fs.readFileSync("/etc/node-rai/cert/test-rai.csr")
};
// Expose to the world
diff --git a/debian/tests/control b/debian/tests/control
index b07f5e0..607ce88 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -1,2 +1,2 @@
Tests: require
-Depends: node-rai
+Depends: openssl, node-rai
diff --git a/debian/tests/require b/debian/tests/require
index dd36be9..0ce858c 100644
--- a/debian/tests/require
+++ b/debian/tests/require
@@ -1,3 +1,25 @@
-#!/bin/sh
+#!/bin/bash
+
set -e
+
+OPENSSL=/usr/bin/openssl
+
+cleanup() {
+ [ -z "$DIR" ] || rm -rf "$DIR"
+}
+
+#DIR=`mktemp -p . -d`
+DIR=/etc/node-rai/cert
+mkdir -p $DIR
+
+trap cleanup EXIT ERR
+
+$OPENSSL genrsa -passout pass:blubber -des3 -out $DIR/test-rai.key 1024 &> /dev/null
+$OPENSSL req -passin pass:blubber -passout pass:blubber -new -key $DIR/test-rai.key -out $DIR/test-rai.csr -batch &> /dev/null
+$OPENSSL x509 -passin pass:blubber -req -days 365 -in $DIR/test-rai.csr -signkey $DIR/test-rai.key -out $DIR/test-rai.crt &> /dev/null
+
+ls -l $DIR
+
nodejs -e "require('rai');"
+
+exit 0
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-rai.git
More information about the Pkg-javascript-commits
mailing list