forked from cvat-ai/cvat
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Synchronize the main and full workflows (cvat-ai#5875)
The full workflow is broken, because some changes from the main workflow weren't applied to it. Update them both to minimize differences between them.
- Loading branch information
Showing
2 changed files
with
17 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,6 +14,7 @@ on: | |
env: | ||
WORKFLOW_RUN_URL: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }} | ||
CYPRESS_VERIFY_TIMEOUT: 180000 # https://docs.cypress.io/guides/guides/command-line#cypress-verify | ||
CVAT_VERSION: "local" | ||
|
||
jobs: | ||
search_cache: | ||
|
@@ -41,10 +42,6 @@ jobs: | |
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
with: | ||
# we specify version of buildkit due to issue that occurs in latest version | ||
# https://github.com/moby/buildkit/issues/2631 | ||
driver-opts: image=moby/buildkit:v0.10.0 | ||
|
||
- name: Create artifact directories | ||
run: | | ||
|
@@ -95,7 +92,7 @@ jobs: | |
name: cvat_sdk | ||
path: /tmp/cvat_sdk/ | ||
|
||
rest_api: | ||
rest_api_testing: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
@@ -107,9 +104,6 @@ jobs: | |
with: | ||
python-version: '3.8' | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@master | ||
|
||
- name: Download CVAT server image | ||
uses: actions/download-artifact@v3 | ||
with: | ||
|
@@ -132,8 +126,8 @@ jobs: | |
run: | | ||
docker load --input /tmp/cvat_server/image.tar | ||
docker load --input /tmp/cvat_ui/image.tar | ||
docker tag cvat/server:latest cvat/server:dev | ||
docker tag cvat/ui:latest cvat/ui:dev | ||
docker tag cvat/server:latest cvat/server:${CVAT_VERSION} | ||
docker tag cvat/ui:latest cvat/ui:${CVAT_VERSION} | ||
docker image ls -a | ||
- name: Verify API schema | ||
|
@@ -164,12 +158,12 @@ jobs: | |
pip3 install --user '/tmp/cvat_sdk/[pytorch]' | ||
pip3 install --user cvat-cli/ | ||
pip3 install --user -r tests/python/requirements.txt | ||
pytest tests/python -s -v | ||
pytest tests/python/ -s -v | ||
- name: Creating a log file from cvat containers | ||
if: failure() && steps.run_tests.conclusion == 'failure' | ||
env: | ||
LOGS_DIR: "${{ github.workspace }}/rest_api" | ||
LOGS_DIR: "${{ github.workspace }}/rest_api_testing" | ||
run: | | ||
mkdir $LOGS_DIR | ||
docker logs test_cvat_server_1 > $LOGS_DIR/cvat_server.log | ||
|
@@ -182,7 +176,7 @@ jobs: | |
uses: actions/[email protected] | ||
with: | ||
name: rest_api_container_logs | ||
path: "${{ github.workspace }}/rest_api" | ||
path: "${{ github.workspace }}/rest_api_testing" | ||
|
||
unit_testing: | ||
needs: build | ||
|
@@ -192,19 +186,16 @@ jobs: | |
with: | ||
ref: ${{ inputs.ref }} | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@master | ||
|
||
- name: Download CVAT server image | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: cvat_server | ||
path: /tmp/cvat_server/ | ||
|
||
- name: Load Docker images | ||
- name: Load Docker server image | ||
run: | | ||
docker load --input /tmp/cvat_server/image.tar | ||
docker tag cvat/server:latest cvat/server:dev | ||
docker tag cvat/server:latest cvat/server:${CVAT_VERSION} | ||
docker image ls -a | ||
- name: Running OPA tests | ||
|
@@ -222,6 +213,7 @@ jobs: | |
CONTAINER_COVERAGE_DATA_DIR: "/coverage_data" | ||
run: | | ||
docker compose -f docker-compose.yml -f docker-compose.dev.yml up -d cvat_opa cvat_server | ||
max_tries=12 | ||
while [[ $(curl -s -o /dev/null -w "%{http_code}" localhost:8181/health?bundles) != "200" && max_tries -gt 0 ]]; do (( max_tries-- )); sleep 5; done | ||
|
@@ -266,9 +258,6 @@ jobs: | |
with: | ||
node-version: '16.x' | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@master | ||
|
||
- name: Download CVAT server image | ||
uses: actions/download-artifact@v3 | ||
with: | ||
|
@@ -285,8 +274,8 @@ jobs: | |
run: | | ||
docker load --input /tmp/cvat_server/image.tar | ||
docker load --input /tmp/cvat_ui/image.tar | ||
docker tag cvat/server:latest cvat/server:dev | ||
docker tag cvat/ui:latest cvat/ui:dev | ||
docker tag cvat/server:latest cvat/server:${CVAT_VERSION} | ||
docker tag cvat/ui:latest cvat/ui:${CVAT_VERSION} | ||
docker image ls -a | ||
- name: Run CVAT instance | ||
|
@@ -308,6 +297,7 @@ jobs: | |
do | ||
echo Number of attempts left: $max_tries | ||
echo Status code of response: $status_code | ||
sleep 5 | ||
status_code=$(curl -s -o /tmp/server_response -w "%{http_code}" ${API_ABOUT_PAGE}) | ||
(( max_tries-- )) | ||
|
@@ -323,7 +313,6 @@ jobs: | |
cd ./tests | ||
yarn --frozen-lockfile | ||
shopt -s extglob | ||
if [[ ${{ matrix.specs }} == canvas3d_* ]]; then | ||
npx cypress run \ | ||
--headed \ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters