Skip to content

Commit

Permalink
Merge pull request #16 from srz-zumix/feature/reduce_restart
Browse files Browse the repository at this point in the history
reduce restart
  • Loading branch information
srz-zumix committed May 18, 2022
2 parents be584b3 + aed9060 commit d0087e0
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
10 changes: 10 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,16 @@ runs:
run: |
"${GITHUB_ACTION_PATH}/install-plugins.sh" "${{ inputs.plugins_file }}"
if: "inputs.plugins_file != ''"
- name: Restart Jenkins
shell: bash
env:
JENKINS_SERVICE_ID: ${{ inputs.id }}
run: |
"${GITHUB_ACTION_PATH}/restart-and-wait.sh"
if: >
inputs.plugins_file != '' &&
inputs.plugins != '' &&
inputs.install_suggested_plugins == 'true'
- name: Setup JCasC
shell: bash
if: "inputs.jcasc_path != ''"
Expand Down
3 changes: 0 additions & 3 deletions install-plugins-fromenv.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,4 @@ if [ -n "${INSTALL_PLUGINS}" ]; then
echo '::group::jenkins plugin install'
echo "${INSTALL_PLUGINS}" | xargs -I{} jenkins-cli install-plugin {}
echo '::endgroup::'

# restart
"${GITHUB_ACTION_PATH}/restart-and-wait.sh"
fi
3 changes: 0 additions & 3 deletions install-plugins.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,4 @@ if [ -f "${PLUGIN_FILES}" ]; then
echo '::group::jenkins plugin install'
xargs -I{} jenkins-cli install-plugin {} < "${PLUGIN_FILES}"
echo '::endgroup::'

# restart
"${GITHUB_ACTION_PATH}/restart-and-wait.sh"
fi

0 comments on commit d0087e0

Please sign in to comment.