Skip to content

Commit

Permalink
Default qualifier to alpha1 and fix workflows (opensearch-project#269)
Browse files Browse the repository at this point in the history
* Default qualifier to alpha1 and fix workflows

Signed-off-by: Peter Zhu <[email protected]>

* temp block docker as PA not ready yet

Signed-off-by: Peter Zhu <[email protected]>

* temp block docker as PA not ready yet

Signed-off-by: Peter Zhu <[email protected]>
  • Loading branch information
peterzhuamazon authored Mar 31, 2022
1 parent 3125b53 commit 0363e4e
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 10 deletions.
25 changes: 16 additions & 9 deletions .github/workflows/CI-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,25 @@ jobs:
# ToDo: Check infra team for 2.0 docker availability and re-enable
# - name: Pull and Run Docker
# run: |
# plugin=`ls plugin/build/distributions/*.zip`
# echo MLCommons plugin $plugin
# version=2.0.0
# plugin_version=2.0.0-SNAPSHOT
# echo Using OpenSearch $version with MLCommons $plugin_version
# plugin=`basename $(ls plugin/build/distributions/*.zip)`
# version=`echo $plugin|awk -F- '{print $3}'| cut -d. -f 1-3`
# plugin_version=`echo $plugin|awk -F- '{print $3}'| cut -d. -f 1-4`
# qualifier=`echo $plugin|awk -F- '{print $4}'| cut -d. -f 1-1`
# candidate_version=`echo $plugin|awk -F- '{print $5}'| cut -d. -f 1-1`
# docker_version=$version-$qualifier
#
# [[ -z $candidate_version ]] && candidate_version=$qualifier && qualifier=""
#
# echo plugin version plugin_version qualifier candidate_version docker_version
# echo "($plugin) ($version) ($plugin_version) ($qualifier) ($candidate_version) ($docker_version)"
#
# cd ..
# if docker pull opensearchstaging/opensearch:$version
# if docker pull opensearchstaging/opensearch:$docker_version
# then
# echo "FROM opensearchstaging/opensearch:$version" >> Dockerfile
# echo "FROM opensearchstaging/opensearch:$docker_version" >> Dockerfile
# echo "RUN if [ -d /usr/share/opensearch/plugins/opensearch-ml ]; then /usr/share/opensearch/bin/opensearch-plugin remove opensearch-ml; fi" >> Dockerfile
# echo "ADD ml-commons/plugin/build/distributions/opensearch-ml-$plugin_version.zip /tmp/" >> Dockerfile
# echo "RUN /usr/share/opensearch/bin/opensearch-plugin install --batch file:/tmp/opensearch-ml-$plugin_version.zip" >> Dockerfile
# echo "ADD ml-commons/plugin/build/distributions/$plugin /tmp/" >> Dockerfile
# echo "RUN /usr/share/opensearch/bin/opensearch-plugin install --batch file:/tmp/$plugin" >> Dockerfile
# docker build -t opensearch-ml:test .
# echo "imagePresent=true" >> $GITHUB_ENV
# else
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ buildscript {
opensearch_group = "org.opensearch"
isSnapshot = "true" == System.getProperty("build.snapshot", "true")
opensearch_version = System.getProperty("opensearch.version", "2.0.0-alpha1-SNAPSHOT")
buildVersionQualifier = System.getProperty("build.version_qualifier")
buildVersionQualifier = System.getProperty("build.version_qualifier", "alpha1")

// 2.0.0-alpha1-SNAPSHOT -> 2.0.0.0-alpha1-SNAPSHOT
version_tokens = opensearch_version.tokenize('-')
Expand Down

0 comments on commit 0363e4e

Please sign in to comment.