diff --git a/.github/workflows/.security-test-workflow.yml.swp b/.github/workflows/.security-test-workflow.yml.swp new file mode 100644 index 000000000..c5958f93e Binary files /dev/null and b/.github/workflows/.security-test-workflow.yml.swp differ diff --git a/yaml/bwc-test-workflow.yml b/.github/workflows/bwc-test-workflow.yml similarity index 58% rename from yaml/bwc-test-workflow.yml rename to .github/workflows/bwc-test-workflow.yml index 66174c697..be0e165c4 100644 --- a/yaml/bwc-test-workflow.yml +++ b/.github/workflows/bwc-test-workflow.yml @@ -9,14 +9,25 @@ on: - "*" jobs: - build: - strategy: - matrix: - java: [ 11 ] + Get-CI-Image-Tag: + uses: ./.github/workflows/get-ci-image-tag.yml + with: + platform: centos7 + usage: opensearch + + build-linux: + needs: Get-CI-Image-Tag # Job name name: Build and test Alerting # This job runs on Linux runs-on: ubuntu-latest + container: + # using the same image which is used by opensearch-build team to build the OpenSearch Distribution + # this image tag is subject to change as more dependencies and updates will arrive over time + image: ${{ needs.Get-CI-Image-Tag.outputs.ci-image-version-linux }} + # need to switch to root so that github actions can install runner binary on container without permission issues. + options: --user root + steps: # This step uses the setup-java Github action: https://github.com/actions/setup-java - name: Set Up JDK ${{ matrix.java }} @@ -34,4 +45,5 @@ jobs: - name: Run Alerting Backwards Compatibility Tests run: | echo "Running backwards compatibility tests..." - ./gradlew bwcTestSuite + chown -R opensearch.opensearch `pwd` + su opensearch -c "whoami && java -version && ./gradlew bwcTestSuite" diff --git a/yaml/multi-node-test-workflow.yml b/.github/workflows/multi-node-test-workflow.yml similarity index 51% rename from yaml/multi-node-test-workflow.yml rename to .github/workflows/multi-node-test-workflow.yml index b6377ed5d..b80f04a43 100644 --- a/yaml/multi-node-test-workflow.yml +++ b/.github/workflows/multi-node-test-workflow.yml @@ -9,7 +9,14 @@ on: - "*" jobs: - build: + Get-CI-Image-Tag: + uses: ./.github/workflows/get-ci-image-tag.yml + with: + platform: centos7 + usage: opensearch + + build-linux: + needs: Get-CI-Image-Tag strategy: matrix: java: [ 11, 17 ] @@ -17,6 +24,13 @@ jobs: name: Build and test Alerting # This job runs on Linux runs-on: ubuntu-latest + container: + # using the same image which is used by opensearch-build team to build the OpenSearch Distribution + # this image tag is subject to change as more dependencies and updates will arrive over time + image: ${{ needs.Get-CI-Image-Tag.outputs.ci-image-version-linux }} + # need to switch to root so that github actions can install runner binary on container without permission issues. + options: --user root + steps: # This step uses the setup-java Github action: https://github.com/actions/setup-java - name: Set Up JDK ${{ matrix.java }} @@ -27,4 +41,6 @@ jobs: - name: Checkout Branch uses: actions/checkout@v2 - name: Run integration tests with multi node config - run: ./gradlew integTest -PnumNodes=3 + run: | + chown -R opensearch.opensearch `pwd` + su opensearch -c "whoami && java -version && ./gradlew integTest -PnumNodes=3" diff --git a/yaml/dco.yml b/yaml/dco.yml deleted file mode 100644 index 53ed5304c..000000000 --- a/yaml/dco.yml +++ /dev/null @@ -1,18 +0,0 @@ -name: Developer Certificate of Origin Check - -on: [pull_request] - -jobs: - check: - runs-on: ubuntu-latest - - steps: - - name: Get PR Commits - id: 'get-pr-commits' - uses: tim-actions/get-pr-commits@v1.1.0 - with: - token: ${{ secrets.GITHUB_TOKEN }} - - name: DCO Check - uses: tim-actions/dco@v1.1.0 - with: - commits: ${{ steps.get-pr-commits.outputs.commits }} \ No newline at end of file diff --git a/.github/workflows/security-test-workflow.yml b/yaml/security-test-workflow.yml similarity index 100% rename from .github/workflows/security-test-workflow.yml rename to yaml/security-test-workflow.yml