15
17

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Jenkins 上流から下流へパラメーター渡して受け取る

Last updated at Posted at 2016-08-09

■Jenkinsの管理→プラグインの管理→「Parameterized Trigger plugin」をインストール

■上流ジョブを開いて「ビルドのパラメータ化」にチェックをいれて引数を設定する。

Jenkins下流ジョブのビルドのパラメーター化.png

■上流ジョブのビルド後の処理に追加で「Trigger parameterized build on other projects」を選択
 下流ジョブ名をProject to build に入力して、「Add parameters」から「Current build parameters」を追加

Jenkinsビルド後の処理.png

 

■下流ジョブ側でも同じように「ビルドのパラメータ化」にチェックをいれて引数を設定する。
 こうしないと引数を受け取れないみたい。

Jenkins下流ジョブのビルドのパラメーター化.png

 

■ビルドにシェルスクリプトを追加して、
 シェルの実行の中に echo $Output 等を書いてパラメータが渡っている事を確認

 

15
17
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
15
17

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?