summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2018-02-23 15:58:57 +0200
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2018-02-26 16:06:49 +0200
commit645dceb0a233fc523ac16611fa3fec317d29a7e1 (patch)
tree4bfc439d7720d8e7f715c749d5837088641418f2 /plugins
parenteff5746b5e7cf4075edd6d1c76fdcd24c1603bb4 (diff)
downloadgitlab-ce-645dceb0a233fc523ac16611fa3fec317d29a7e1.tar.gz
Run plugins as separate process and pass data via STDIN
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'plugins')
-rwxr-xr-xplugins/available/save_to_file.clj3
-rwxr-xr-xplugins/available/save_to_file.rb3
-rw-r--r--plugins/enabled/.gitkeep (renamed from plugins/.gitkeep)0
3 files changed, 6 insertions, 0 deletions
diff --git a/plugins/available/save_to_file.clj b/plugins/available/save_to_file.clj
new file mode 100755
index 00000000000..a59d83749d3
--- /dev/null
+++ b/plugins/available/save_to_file.clj
@@ -0,0 +1,3 @@
+#!/usr/bin/env clojure
+(let [in (slurp *in*)]
+ (spit "/tmp/clj-data.txt" in))
diff --git a/plugins/available/save_to_file.rb b/plugins/available/save_to_file.rb
new file mode 100755
index 00000000000..61b0df9bfd6
--- /dev/null
+++ b/plugins/available/save_to_file.rb
@@ -0,0 +1,3 @@
+#!/usr/bin/env ruby
+x = STDIN.read
+File.write('/tmp/rb-data.txt', x)
diff --git a/plugins/.gitkeep b/plugins/enabled/.gitkeep
index e69de29bb2d..e69de29bb2d 100644
--- a/plugins/.gitkeep
+++ b/plugins/enabled/.gitkeep