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

Update full-build.yaml #109

Merged
merged 1 commit into from
Sep 29, 2023
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
27 changes: 15 additions & 12 deletions pipelines/full-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ stages:
inputs:
versionSpec: 3.9
- script: |
set -x # Echo commands before they are run
set -ex # Echo commands before they are run

# Figure out what the build kind is
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/"}
Expand Down Expand Up @@ -131,7 +131,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}
if [[ "$TAG" == *stable* ]]; then export BUILD_TYPE=stable; else export BUILD_TYPE=latest; fi
export VERSION=${TAG/stable}
Expand All @@ -157,7 +157,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}
if [[ "$TAG" == *stable* ]]; then export BUILD_TYPE=stable; else export BUILD_TYPE=latest; fi
export VERSION=${TAG/stable}
Expand Down Expand Up @@ -197,7 +197,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}
if [[ "$TAG" == *stable* ]]; then export BUILD_TYPE=stable; else export BUILD_TYPE=latest; fi
export VERSION=${TAG/stable}
Expand Down Expand Up @@ -230,7 +230,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}
if [[ "$TAG" == *stable* ]]; then export BUILD_TYPE=stable; else export BUILD_TYPE=latest; fi
export VERSION=${TAG/stable}
Expand Down Expand Up @@ -263,7 +263,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}
if [[ "$TAG" == *stable* ]]; then export BUILD_TYPE=stable; else export BUILD_TYPE=latest; fi
export VERSION=${TAG/stable}
Expand Down Expand Up @@ -305,7 +305,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}
if [[ "$TAG" == *stable* ]]; then export BUILD_TYPE=stable; else export BUILD_TYPE=latest; fi
export VERSION=${TAG/stable}
Expand Down Expand Up @@ -359,7 +359,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}

cd assemblyline-base
Expand Down Expand Up @@ -390,7 +390,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}

cd assemblyline-core
Expand Down Expand Up @@ -421,6 +421,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -e
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}

docker run -d --name ui --network host -v $(Pipeline.Workspace)/working/pipelines/ui-config.yaml:/etc/assemblyline/config.yml -v $(Pipeline.Workspace)/working/pipelines/classification.yaml:/etc/assemblyline/classification.yml --restart on-failure cccstemp.azurecr.io/assemblyline-ui:$TAG &
Expand Down Expand Up @@ -473,6 +474,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -e
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}

docker run -d --name server --network host --restart on-failure cccstemp.azurecr.io/assemblyline-service-server:$TAG
Expand Down Expand Up @@ -504,6 +506,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -e
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}

docker run -v `pwd`/test:/test \
Expand All @@ -527,7 +530,7 @@ stages:
- download: current
artifact: working
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
sudo env "PATH=$PATH" python -m pip install --no-cache-dir -U 'urllib3<2' twine
ls dist
twine upload --skip-existing dist/*
Expand Down Expand Up @@ -586,7 +589,7 @@ stages:
command: login
containerRegistry: CHIMERA-U-ACR
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}
if [[ "$TAG" == *stable* ]]; then export BUILD_TYPE=stable; else export BUILD_TYPE=latest; fi
export VERSION=${TAG/stable}
Expand Down Expand Up @@ -618,7 +621,7 @@ stages:
command: login
containerRegistry: cccstemp
- script: |
set -xv # Echo commands before they are run
set -exv # Echo commands before they are run
export TAG=${BUILD_SOURCEBRANCH#"refs/tags/v"}

# Prepare output directory
Expand Down