From 9cff9db38e7b93066ecdb585e6f340aef6c74f76 Mon Sep 17 00:00:00 2001 From: Ivan Remizov Date: Thu, 4 May 2017 23:00:24 +0300 Subject: [PATCH] Create sample layout for library This patch creates directory layout. This layout is not final and will be changed in future --- .gitignore | 8 ++++++++ conf/jenkins_job.ini.example | 13 +++++++++++++ conf/requirements.txt | 2 ++ library/macros/.gitkeep | 0 library/scripts/.gitkeep | 0 library/templates/.gitkeep | 0 servers/example/projects/.gitkeep | 0 tox.ini | 21 +++++++++++++++++++++ 8 files changed, 44 insertions(+) create mode 100644 .gitignore create mode 100644 conf/jenkins_job.ini.example create mode 100644 conf/requirements.txt create mode 100644 library/macros/.gitkeep create mode 100644 library/scripts/.gitkeep create mode 100644 library/templates/.gitkeep create mode 100644 servers/example/projects/.gitkeep create mode 100644 tox.ini diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b5e910a --- /dev/null +++ b/.gitignore @@ -0,0 +1,8 @@ +*.pyc +output/ +*.ini +!tox.ini +.tox +.idea +.venv +venv diff --git a/conf/jenkins_job.ini.example b/conf/jenkins_job.ini.example new file mode 100644 index 0000000..95c89ed --- /dev/null +++ b/conf/jenkins_job.ini.example @@ -0,0 +1,13 @@ +[jenkins] +user=my_username +password=my_secret_password +url=https://my.jenkins.com/ +query_plugins_info=False + +[job_builder] +ignore_cache=True +keep_descriptions=False +recursive=True + +[__future__] +param_order_from_yaml=false diff --git a/conf/requirements.txt b/conf/requirements.txt new file mode 100644 index 0000000..f9032bc --- /dev/null +++ b/conf/requirements.txt @@ -0,0 +1,2 @@ +jenkins-job-builder==1.6.1 +git+https://github.com/bookwar/jenkins-job-builder-stash-pr diff --git a/library/macros/.gitkeep b/library/macros/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/library/scripts/.gitkeep b/library/scripts/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/library/templates/.gitkeep b/library/templates/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/servers/example/projects/.gitkeep b/servers/example/projects/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/tox.ini b/tox.ini new file mode 100644 index 0000000..2b6fdb4 --- /dev/null +++ b/tox.ini @@ -0,0 +1,21 @@ +[tox] +minversion = 1.6 +skipsdist = True +envlist = example,pep8 + +[testenv] +basepython = python2 +deps = -r{toxinidir}/conf/requirements.txt +usedevelop = False +commands = + jenkins-jobs --conf conf/jenkins_job.ini.example test servers/{envname}:library -o {toxinidir}/output/{envname} + +[testenv:pep8] +deps = flake8 +commands = flake8 + +[flake8] +exclude = .git,.tox,.venv,venv +show-pep8 = True +show-source = True +count = True