diff options
authorPaul Sokolovsky <pfalcon@users.sourceforge.net>2015-03-26 16:27:30 +0200
committerPaul Sokolovsky <pfalcon@users.sourceforge.net>2015-03-26 16:27:30 +0200
commitbc72df4b7f6b5c2a7ab13521456a1eba0b876eec (patch)
parent38d25bfc8d30b89305093312c4f331fc86f20c27 (diff)
Add README, providing basic facts and deployment instructions.
Change-Id: I7df225b553c0e884e939a05290fe8f5f89e0ce26
1 files changed, 45 insertions, 0 deletions
diff --git a/README.txt b/README.txt
new file mode 100644
index 0000000..ab32f86
--- /dev/null
+++ b/README.txt
@@ -0,0 +1,45 @@
+jenkins-plugin-linaro-pubapi is Jenkins plugin to integrate with Linaro
+Publishing API (which is integral part of linaro-license-publishing,
+Integration handled by the plugin is the minimal required to keep
+publishing secure, namely requesting a "one-time" publishing token from
+the service in a secure manner, actual publishing is handled as a
+part of build process using linaro-cp command-line tool
+(https://git.linaro.org/ci/publishing-api.git), which allows great
+flexibility and easy ways to debug.
+Installation and basic testing
+1. Install "Linaro Publishing API Token Plugin" - done by Ansible on
+production Jenkins hosts, you may need to build plugin and/or install it
+manually otherwise.
+2. Login to https://snapshots.linaro.org/login/
+3. Go to https://snapshots.linaro.org/admin/
+4. Browse "Api key stores" table for a key for ci.linaro.org, or create
+it (create as "Public")
+5. https://ci.linaro.org/configure : search for "Linaro Publishing"
+6. Set "Secret key" to value generated in snapshots/admin above.
+7. Check values of "not valid before" & "not valid after". For testing
+below, you'll need to set "not valid before" to 0.
+8. Create a test job, say "newpub-test" (prefix with your username)
+9. As first build step, add "Linaro Publish API Token"
+10. As 2nd step, add "Execute shell" with script:
+11. Run job, make sure it builds, non-empty value is printed
+12. Now replace script content with:
+mkdir -p out
+echo foo >out/result.txt
+wget https://git.linaro.org/ci/publishing-api.git/blob_plain/HEAD:/linaro-cp.py -O linaro-cp.py
+python linaro-cp.py out /tmp/$JOB_NAME/$BUILD_NUMBER
+(adjust destination path as needed)
+13. Run job, make sure it succeeds and files are available on publishing server.
+If you get "token no longer valid", adjust "token not valid before" setting in global
+config (see above).