Skip to content

World's most powerful open data catalog for building a high-performance, geo-distributed and federated metadata lake.

[#2379] fix(hive-ci-image): Let user hive be able to access MySQL (#2523)

charliecheng63083e0e6b7a0b9
diff --git a/catalogs/catalog-hadoop/build.gradle.kts b/catalogs/catalog-hadoop/build.gradle.kts
index a5ce82c098..842c165f7a 100644
--- a/catalogs/catalog-hadoop/build.gradle.kts
+++ b/catalogs/catalog-hadoop/build.gradle.kts
@@ -95,7 +95,7 @@ tasks.test {
dependsOn(tasks.jar)
doFirst {
- environment("GRAVITINO_CI_HIVE_DOCKER_IMAGE", "datastrato/gravitino-ci-hive:0.1.8")
+ environment("GRAVITINO_CI_HIVE_DOCKER_IMAGE", "datastrato/gravitino-ci-hive:0.1.9")
}
val init = project.extra.get("initIntegrationTest") as (Test) -> Unit
diff --git a/catalogs/catalog-hive/build.gradle.kts b/catalogs/catalog-hive/build.gradle.kts
index d368f8a735..ef761ece21 100644
--- a/catalogs/catalog-hive/build.gradle.kts
+++ b/catalogs/catalog-hive/build.gradle.kts
@@ -162,7 +162,7 @@ tasks.test {
dependsOn(tasks.jar)
doFirst {
- environment("GRAVITINO_CI_HIVE_DOCKER_IMAGE", "datastrato/gravitino-ci-hive:0.1.8")
+ environment("GRAVITINO_CI_HIVE_DOCKER_IMAGE", "datastrato/gravitino-ci-hive:0.1.9")
}
val init = project.extra.get("initIntegrationTest") as (Test) -> Unit
diff --git a/catalogs/catalog-lakehouse-iceberg/build.gradle.kts b/catalogs/catalog-lakehouse-iceberg/build.gradle.kts
index e98927d367..ae61b173cc 100644
--- a/catalogs/catalog-lakehouse-iceberg/build.gradle.kts
+++ b/catalogs/catalog-lakehouse-iceberg/build.gradle.kts
@@ -161,7 +161,7 @@ tasks.test {
dependsOn(tasks.jar)
doFirst {
- environment("GRAVITINO_CI_HIVE_DOCKER_IMAGE", "datastrato/gravitino-ci-hive:0.1.8")
+ environment("GRAVITINO_CI_HIVE_DOCKER_IMAGE", "datastrato/gravitino-ci-hive:0.1.9")
}
val init = project.extra.get("initIntegrationTest") as (Test) -> Unit
diff --git a/dev/docker/hive/Dockerfile b/dev/docker/hive/Dockerfile
index 09c3689300..2dbcd786a0 100644
--- a/dev/docker/hive/Dockerfile
+++ b/dev/docker/hive/Dockerfile
@@ -38,9 +38,7 @@ RUN apt-get update && apt-get upgrade -y && apt-get install --fix-missing -yq \
openssh-server \
wget \
sudo \
- openjdk-8-jdk \
- mysql-server \
- && rm -rf /var/lib/apt/lists/*
+ openjdk-8-jdk
#################################################################################
## setup ssh
@@ -125,6 +123,7 @@ ADD hive-site.xml ${HIVE_HOME}/conf/hive-site.xml
ENV MYSQL_PWD=ds123
RUN echo "mysql-server mysql-server/root_password password ${MYSQL_PWD}" | debconf-set-selections
RUN echo "mysql-server mysql-server/root_password_again password ${MYSQL_PWD}" | debconf-set-selections
+RUN apt-get install -y mysql-server
RUN chown -R mysql:mysql /var/lib/mysql
RUN usermod -d /var/lib/mysql/ mysql
@@ -150,8 +149,9 @@ RUN mkdir /home/datastrato
RUN chown -R datastrato:hadoop /home/datastrato
################################################################################
-# removed install packages
+# removed install packages and cache
RUN rm -rf /tmp/packages
+RUN rm -rf /var/lib/apt/lists/*
################################################################################
# expose port
diff --git a/docs/docker-image-details.md b/docs/docker-image-details.md
index 116d81f6ae..9c826da483 100644
--- a/docs/docker-image-details.md
+++ b/docs/docker-image-details.md
@@ -82,6 +82,9 @@ You can use this kind of image to test the catalog of Apache Hive.
Changelog
+- gravitino-ci-hive:0.1.9
+ - Remove cache after installing packages.
+
- gravitino-ci-hive:0.1.8
- Change the value of `hive.server2.enable.doAs` to `true`
diff --git a/integration-test/build.gradle.kts b/integration-test/build.gradle.kts
index ed7bc7be57..0aacb8399a 100644
--- a/integration-test/build.gradle.kts
+++ b/integration-test/build.gradle.kts
@@ -147,7 +147,7 @@ tasks.test {
doFirst {
// Gravitino CI Docker image
- environment("GRAVITINO_CI_HIVE_DOCKER_IMAGE", "datastrato/gravitino-ci-hive:0.1.8")
+ environment("GRAVITINO_CI_HIVE_DOCKER_IMAGE", "datastrato/gravitino-ci-hive:0.1.9")
environment("GRAVITINO_CI_TRINO_DOCKER_IMAGE", "datastrato/gravitino-ci-trino:0.1.5")
copy {
diff --git a/integration-test/trino-it/docker-compose.yaml b/integration-test/trino-it/docker-compose.yaml
index ed783265b1..c099a919e8 100644
--- a/integration-test/trino-it/docker-compose.yaml
+++ b/integration-test/trino-it/docker-compose.yaml
@@ -6,7 +6,7 @@ version: '3.0'
services:
hive:
- image: datastrato/gravitino-ci-hive:0.1.8
+ image: datastrato/gravitino-ci-hive:0.1.9
networks:
- trino-net
container_name: trino-ci-hive