Skip to content

Commit

Permalink
XWDOCKER-282: Update the process to use an external Solr instance
Browse files Browse the repository at this point in the history
- Make the solr folder build

Signed-off-by: GridexX <[email protected]>
  • Loading branch information
GridexX committed Jul 21, 2023
1 parent f8f666f commit 74ca371
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
6 changes: 5 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import org.apache.tools.ant.filters.ReplaceTokens

defaultTasks 'generate'

def variants = ['mysql-tomcat', 'mariadb-tomcat', 'postgres-tomcat']
def variants = ['mysql-tomcat', 'mariadb-tomcat', 'postgres-tomcat', 'solr-tomcat']

// Notes:
// - To compute the XWiki sha256, download the XWiki WAR from
Expand All @@ -45,6 +45,8 @@ def variants = ['mysql-tomcat', 'mariadb-tomcat', 'postgres-tomcat']
def tokens = [
'15': [
xwikiVersion: '15.5',
solrCoreUrl: 'https://maven.xwiki.org/releases/org/xwiki/platform/xwiki-platform-search-solr-server-core/15.5/xwiki-platform-search-solr-server-core-15.5.jar',
solrMinimalCoreUrl: 'https://maven.xwiki.org/releases/org/xwiki/platform/xwiki-platform-search-solr-server-core-minimal/15.5/xwiki-platform-search-solr-server-core-minimal-15.5.zip',
xwikiSha256: 'e552586d371da33b012cfbd974b3ba80d1b147a5c892ad6cf989960212cdaa02',
mysqlJDBCVersion: '8.0.33',
mysqlJDBCSha256: 'e2a3b2fc726a1ac64e998585db86b30fa8bf3f706195b78bb77c5f99bf877bd9',
Expand All @@ -53,6 +55,8 @@ def tokens = [
],
'14': [
xwikiVersion: '14.10.14',
solrCoreUrl: 'https://maven.xwiki.org/releases/org/xwiki/platform/xwiki-platform-search-solr-server-core/14.10.14/xwiki-platform-search-solr-server-core-14.10.14.jar',
solrMinimalCoreUrl: 'https://maven.xwiki.org/releases/org/xwiki/platform/xwiki-platform-search-solr-server-core-minimal/14.10.14/xwiki-platform-search-solr-server-core-minimal-14.10.14.zip',
xwikiSha256: 'db20de131a847c8d9e52cc410db35216c494179dd2ac85dcf3cee9a35703bcb0',
mysqlJDBCVersion: '8.0.33',
mysqlJDBCSha256: 'e2a3b2fc726a1ac64e998585db86b30fa8bf3f706195b78bb77c5f99bf877bd9',
Expand Down
10 changes: 4 additions & 6 deletions template/solr/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,13 @@

# Use the curl image to download required Solr cores
FROM curlimages/curl:8.2.0 AS downloader
ARG XWIKI_VERSION=15.5
WORKDIR /home/curl_user
ENV SOLR_SERVER_CORE_URL=https://maven.xwiki.org/releases/org/xwiki/platform/xwiki-platform-search-solr-server-core/${XWIKI_VERSION}/xwiki-platform-search-solr-server-core-${XWIKI_VERSION}.jar
ENV SOLR_CORE_MINIMAL_URL=https://maven.xwiki.org/releases/org/xwiki/platform/xwiki-platform-search-solr-server-core-minimal/${XWIKI_VERSION}/xwiki-platform-search-solr-server-core-minimal-${XWIKI_VERSION}.zip
ENV solrCoreUrl="$solrCoreUrl"
ENV solrMinimalCoreUrl="$solrMinimalCoreUrl"

# Downloading the Solr cores
RUN echo $SOLR_SERVER_CORE_URL && \
curl $SOLR_SERVER_CORE_URL -o ./xwiki-server-core.zip && \
curl $SOLR_CORE_MINIMAL_URL -o ./xwiki-minimal-core.zip
RUN curl $solrCoreUrl -o ./xwiki-server-core.zip && \
curl $solrMinimalCoreUrl -o ./xwiki-minimal-core.zip

# Unzipping the downloaded Solr cores
FROM dockerqa/unzip:latest AS builder
Expand Down

0 comments on commit 74ca371

Please sign in to comment.