From 4aef88b8d75b3d9e8490e4063120af5a7a2eddf0 Mon Sep 17 00:00:00 2001 From: Pavel Kachalouski Date: Sun, 22 Jan 2023 13:49:13 +0100 Subject: [PATCH] SQL --- Jenkinsfile | 24 ++++++------------------ 1 file changed, 6 insertions(+), 18 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 8b50deb..5b7063c 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,19 +1,7 @@ -pipeline { - agent any - options { - skipStagesAfterUnstable() - } - stages { - stage('Build') { - steps { - node { - import groovy.sql.Sql - Class.forName("com.mysql.jdbc.Driver") - def sql = Sql.newInstance("jdbc:mysql://mysql:3306/test_db", "user","passwd", "com.mysql.jdbc.Driver") - def rows = sql.execute "select count(*) from test_table;" - echo rows.dump() - } - } - } - } +import groovy.sql.Sql +node{ + Class.forName("com.mysql.jdbc.Driver") + def sql = Sql.newInstance("jdbc:mysql://mysql:3306/test_db", "user","passwd", "com.mysql.jdbc.Driver") + def rows = sql.execute "select count(*) from test_table;" + echo rows.dump() }