Skip to content
This repository has been archived by the owner on Feb 1, 2023. It is now read-only.

boaglio/jenkins-plugin-sqlplus-script-runner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

87 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jenkins-plugin-sqlplus-script-runner

Jenkins plugin - SQL*Plus Script Runner

This plugin enables you run Oracle SQL*Plus scripts on your Jenkins jobs ( SQL*Plus installation required! ).

All you have to do is provide a valid ORACLE_HOME and you are in business:

Main Setup

You can run a script inside your workspace or a user defined for every job:

Job Setup

You can check later all SQL*Plus output inside your build output:

Script running inside a job

Download the last release and give it a try!

https://github.com/boaglio/jenkins-plugin-sqlplus-script-runner/releases

Developer guide

  1. Fork repository
  2. Code code code
  3. Run it with:
  • mvn clean
  • mvn generate-sources (convert Message*.properties into Messages.java)
  • mvn compiler:compile
  • mvn clean -DskipTests package hpi:run
  1. Try it at http://localhost:8080
  2. Commit and submit pull request

Translator guide

  1. Fork repository
  2. Copy config.properties to config_.properties (example: config_pt_BR.properties)
  3. Copy global.properties to global_.properties
  4. Copy Messages.properties to Messages_.properties
  5. Copy all HTML files too
  6. Translate it
  7. Run it with:
  • mvn clean -DskipTests package hpi:run
  1. Try it at http://localhost:8080
  2. Commit and submit pull request

Pipeline

user defined script

node { echo 'SQLPlusRunner running user define script for system@xe' step([$class: 'SQLPlusRunnerBuilder',credentialsId:'system', instance:'xe',scriptType:'userDefined', script: '',scriptContent: 'select * from v$version']) }

file script

node { echo 'SQLPlusRunner running file script for system@xe' step([$class: 'SQLPlusRunnerBuilder',credentialsId:'system', instance:'xe',scriptType:'file', script: 'start.sql',scriptContent: '']) }

Optional parameters

  • customOracleHome
  • customSQLPlusHome
  • customTNSAdmin

Having problems?

Please open a new issue and inform:

  • Jenkins server Operation System;
  • Jenkins version;
  • Where SQLPlus Script Runner is running (local machine or slave machine);
  • Slave machine Operation System (if applicable);
  • Oracle Database version;
  • Oracle SQL*Plus version;
  • Build log with debug info enabled.