From 7e95688d37ec0948c0a22645c6b4a565d98057f6 Mon Sep 17 00:00:00 2001 From: Peter Mosmans Date: Wed, 10 Aug 2016 15:22:57 +0200 Subject: [PATCH] Added support for NAMESPACEID --- chatops/bash/handler_quote | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/chatops/bash/handler_quote b/chatops/bash/handler_quote index ee825e2..7704b61 100644 --- a/chatops/bash/handler_quote +++ b/chatops/bash/handler_quote @@ -17,13 +17,14 @@ # (at your option) any later version. -VERSION=0.6 +VERSION=0.7 # These variables should be set environment-specific [ -z $GITLABCLI ] && GITLABCLI=gitlab [ -z $GITSERVER ] && GITSERVER=gitlab.local [ -z $NAMESPACE ] && NAMESPACE=ros -[ -z $PENTEXTREPO ] && PENTEXTREPO=https://github.com/radicallyopensecurity/templates +[ -z $NAMESPACEID ] && NAMESPACEID=1 +[ -z $PENTEXTREPO ] && PENTEXTREPO=https://github.com/radicallyopensecurity/pentext PREFIX="off-" pentext=$(echo $PENTEXTREPO|awk -F '/' '{print $5}') TEMPLOC=$(mktemp -d) @@ -71,7 +72,7 @@ preflight_checks() { } setup_repo() { - project_id=$($GITLABCLI project create --name $REPO --issues-enabled true --wiki-enabled true --snippets-enabled true --wall-enabled true --merge-requests-enabled true 2>/dev/null| awk '/id:/{print $2}') + project_id=$($GITLABCLI project create --name $REPO --namespace $NAMESPACEID --issues-enabled true --wiki-enabled true --snippets-enabled true --wall-enabled true --merge-requests-enabled true 2>/dev/null| awk '/id:/{print $2}') if [ ! -z $project_id ]; then echo "[+] successfully created gitlab project $REPO with id ${project_id}" else