Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable custom start commands and options to resolve GHA issues #5189

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions .github/workflows/python-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on: [push, pull_request]
jobs:
Get-CI-Image-Tag:
uses: ./.github/workflows/get-ci-image-tag.yml
with:
product: opensearch
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We add this to opt out the OSD python tests?

Copy link
Member Author

@peterzhuamazon peterzhuamazon Nov 15, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has nothing to do with OSD python test it is just more consistent to find the AL2 image we are retrieving.


python-tests:
strategy:
Expand All @@ -17,7 +19,7 @@ jobs:
env:
PYTHON_VERSION: 3.9
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v3
with:
Expand Down Expand Up @@ -46,17 +48,17 @@ jobs:
python-tests-linux:
needs: Get-CI-Image-Tag
runs-on: ubuntu-latest
env:
ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true
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
options: ${{ needs.Get-CI-Image-Tag.outputs.ci-image-start-options }}

steps:
- uses: actions/checkout@v3
- name: Run start commands
run: ${{ needs.Get-CI-Image-Tag.outputs.ci-image-start-command }}
- uses: actions/checkout@v4
- name: Install Pipenv and Dependencies
run: |
pipenv install
Expand Down
Loading