Skip to content

Commit

Permalink
Jenkins build - Docker image and MySQL (DB + JDBC driver) upgrade (#1794
Browse files Browse the repository at this point in the history
)

This PR contains following changes:

    Updated Docker image used by build
    LANG = 'en_US.UTF-8' environment variable applied to the Jenkins pipelines
    MySQL driver update

Signed-off-by: Radek Felcman <radek.felcman@oracle.com>
  • Loading branch information
rfelcman committed Jan 24, 2023
1 parent b3924ac commit 0f5aff7
Show file tree
Hide file tree
Showing 9 changed files with 42 additions and 22 deletions.
1 change: 1 addition & 0 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ jobs:
mysql -e 'SET GLOBAL log_bin_trust_function_creators = 1;' -uroot -proot
mysql -e 'CREATE DATABASE ecltests;' -uroot -proot
mysql -e 'SHOW DATABASES;' -uroot -proot
mysql -e 'status;' -uroot -proot
- name: Cache local Maven repository
uses: actions/cache@v3
with:
Expand Down
7 changes: 5 additions & 2 deletions etc/jenkins/build.groovy
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//
// Copyright (c) 2019, 2022 Oracle and/or its affiliates. All rights reserved.
// Copyright (c) 2019, 2023 Oracle and/or its affiliates. All rights reserved.
//
// This program and the accompanying materials are made available under the
// terms of the Eclipse Public License v. 2.0 which is available at
Expand Down Expand Up @@ -75,7 +75,7 @@ spec:
requests:
memory: "12Gi"
cpu: "5.5"
image: tkraus/el-build:2.0.2
image: rfelcman/el-build:2.0.3
volumeMounts:
- name: tools
mountPath: /opt/tools
Expand All @@ -99,6 +99,9 @@ spec:
"""
}
}
environment {
LANG = 'en_US.UTF-8'
}
tools {
maven 'apache-maven-latest'
jdk 'openjdk-jdk17-latest'
Expand Down
7 changes: 6 additions & 1 deletion etc/jenkins/docker/image/install.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2022 Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2022, 2023 Oracle and/or its affiliates. All rights reserved.

# This program and the accompanying materials are made available under the
# terms of the Eclipse Public License v. 2.0 which is available at
Expand Down Expand Up @@ -108,6 +108,11 @@ echo '--------------------------------------------------------------------------
#Addtional permanent settings in configuration file
#To disable check for some stored functions
echo 'log_bin_trust_function_creators = 1
character-set-server = utf8mb4
collation-server = utf8mb4_unicode_ci
[mysql]
default-character-set = utf8mb4
' >> /etc/my.cnf
/opt/bin/mysql-start.sh
ROOT_PWD=`cat /var/log/mysqld.log | grep 'A temporary password is generated for root' | sed -e 's/^.*localhost: *//'`
Expand Down
22 changes: 11 additions & 11 deletions etc/jenkins/docker/pom.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2022 Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2022, 2023 Oracle and/or its affiliates. All rights reserved.
This program and the accompanying materials are made available under the
terms of the Eclipse Public License v. 2.0 which is available at
Expand All @@ -24,21 +24,21 @@
<artifactId>org.eclipse.persistence.build.docker</artifactId>
<packaging>pom</packaging>
<!-- Version is used as target docker image tag -->
<version>2.0.2</version>
<version>2.0.3</version>

<properties>
<!-- Source docker image -->
<docker.source>oraclelinux:8</docker.source>
<!-- Target docker image name-->
<docker.image>tkraus/el-build</docker.image>
<docker.image>rfelcman/el-build</docker.image>
<!-- Packages to be installed -->
<java.pkg>jdk-17.0.2_linux-x64_bin.tar.gz</java.pkg>
<java.pkg>jdk-17.0.6_linux-x64_bin.tar.gz</java.pkg>
<java.url>https://download.oracle.com/java/17/archive/${java.pkg}</java.url>
<ant.pkg>apache-ant-1.10.12-bin.tar.gz</ant.pkg>
<ant.pkg>apache-ant-1.10.13-bin.tar.gz</ant.pkg>
<ant.url>https://dlcdn.apache.org//ant/binaries/${ant.pkg}</ant.url>
<maven.pkg>apache-maven-3.8.5-bin.tar.gz</maven.pkg>
<maven.url>https://dlcdn.apache.org/maven/maven-3/3.8.5/binaries/${maven.pkg}</maven.url>
<mysql.pkg>mysql80-community-release-el8-3.noarch.rpm</mysql.pkg>
<maven.pkg>apache-maven-3.8.7-bin.tar.gz</maven.pkg>
<maven.url>https://dlcdn.apache.org/maven/maven-3/3.8.7/binaries/${maven.pkg}</maven.url>
<mysql.pkg>mysql80-community-release-el8-4.noarch.rpm</mysql.pkg>
<mysql.url>https://dev.mysql.com/get/${mysql.pkg}</mysql.url>
<mongo.pkg>mysql80-community-release-el8-3.noarch.rpm</mongo.pkg>
<mongo.url>https://dev.mysql.com/get/${mysql.pkg}</mongo.url>
Expand Down Expand Up @@ -90,17 +90,17 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
</plugin>
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>1.6.1</version>
<version>1.6.8</version>
</plugin>
<plugin>
<groupId>io.fabric8</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>0.39.1</version>
<version>0.40.3</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
Expand Down
7 changes: 5 additions & 2 deletions etc/jenkins/pr_verify.groovy
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//
// Copyright (c) 2021, 2022 Oracle and/or its affiliates. All rights reserved.
// Copyright (c) 2021, 2023 Oracle and/or its affiliates. All rights reserved.
//
// This program and the accompanying materials are made available under the
// terms of the Eclipse Public License v. 2.0 which is available at
Expand Down Expand Up @@ -64,7 +64,7 @@ spec:
requests:
memory: "12Gi"
cpu: "5.5"
image: tkraus/el-build:2.0.2
image: rfelcman/el-build:2.0.3
volumeMounts:
- name: tools
mountPath: /opt/tools
Expand All @@ -90,6 +90,9 @@ spec:
"""
}
}
environment {
LANG = 'en_US.UTF-8'
}
tools {
maven 'apache-maven-latest'
jdk 'openjdk-jdk17-latest'
Expand Down
7 changes: 5 additions & 2 deletions etc/jenkins/release.groovy
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2020, 2022 Oracle and/or its affiliates. All rights reserved.
// Copyright (c) 2020, 2023 Oracle and/or its affiliates. All rights reserved.
//
// This program and the accompanying materials are made available under the
// terms of the Eclipse Distribution License v. 1.0, which is available at
Expand Down Expand Up @@ -70,7 +70,7 @@ spec:
requests:
memory: "4Gi"
cpu: "1.5"
image: tkraus/el-build:2.0.2
image: rfelcman/el-build:2.0.3
volumeMounts:
- name: tools
mountPath: /opt/tools
Expand All @@ -96,6 +96,9 @@ spec:
"""
}
}
environment {
LANG = 'en_US.UTF-8'
}
tools {
maven 'apache-maven-latest'
jdk 'adoptopenjdk-hotspot-jdk11-latest'
Expand Down
7 changes: 5 additions & 2 deletions etc/jenkins/tck.groovy
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
//
// Copyright (c) 2020, 2022 Oracle and/or its affiliates. All rights reserved.
// Copyright (c) 2020, 2023 Oracle and/or its affiliates. All rights reserved.
//
// This program and the accompanying materials are made available under the
// terms of the Eclipse Public License v. 2.0 which is available at
Expand Down Expand Up @@ -47,7 +47,7 @@ spec:
memory: "1Gi"
cpu: "500m"
- name: eclipselink-tck-run
image: tkraus/el-build:2.0.2
image: rfelcman/el-build:2.0.3
resources:
limits:
memory: "3Gi"
Expand All @@ -71,6 +71,9 @@ spec:
"""
}
}
environment {
LANG = 'en_US.UTF-8'
}

stages {
stage('Init') {
Expand Down
4 changes: 3 additions & 1 deletion etc/jenkins/test.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash -e
#
# Copyright (c) 2019, 2022 Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2019, 2023 Oracle and/or its affiliates. All rights reserved.
#
# This program and the accompanying materials are made available under the
# terms of the Eclipse Distribution License v. 1.0, which is available at
Expand All @@ -19,7 +19,9 @@ if [ ${CONTINUOUS_BUILD} = "true" ]; then
mvn -B -V verify -Pstaging
else
echo '-[ EclipseLink LRG Tests ]-----------------------------------------------------------'
env
/opt/bin/mysql-start.sh
mysql -e 'status;' -uroot -proot
mvn -B -V verify -Pstaging,mysql,test-lrg
/opt/bin/mysql-stop.sh
fi
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@
<junit.version>4.13.2</junit.version>
<!-- CQ #24079 -->
<mongodb.version>3.12.11</mongodb.version>
<mysql.version>8.0.28</mysql.version>
<mysql.version>8.0.32</mysql.version>
<mariadb.version>3.1.0</mariadb.version>
<mssql.version>11.2.2.jre11</mssql.version>
<pgsql.version>42.5.1</pgsql.version>
Expand Down

0 comments on commit 0f5aff7

Please sign in to comment.