Skip to content

Commit

Permalink
[CI] Upload artifact should work if only back or front has worked (#9687
Browse files Browse the repository at this point in the history
)
  • Loading branch information
aHenryJard authored Jan 24, 2025
1 parent bcf47c5 commit 0d2a3f8
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,11 @@ steps:
- npm install -g jfrog-cli-v2-jf
# Collect git info
- jf rt bag $JFROG_BUILD_NAME $DRONE_BUILD_NUMBER
# Archive and upload each artefact that we need
- tar -czvf frontend-test-results-$DRONE_BUILD_NUMBER.tar.gz opencti-platform/opencti-front/test-results
- jf rt u frontend-test-results-$DRONE_BUILD_NUMBER.tar.gz $JFROG_REPOSITORY --build-name=$JFROG_BUILD_NAME --build-number=$DRONE_BUILD_NUMBER --url=$JFROG_URL --access-token=$JFROG_TOKEN
- tar -czvf backend-test-results-$DRONE_BUILD_NUMBER.tar.gz opencti-platform/opencti-graphql/test-results
- jf rt u backend-test-results-$DRONE_BUILD_NUMBER.tar.gz $JFROG_REPOSITORY --build-name=$JFROG_BUILD_NAME --build-number=$DRONE_BUILD_NUMBER --url=$JFROG_URL --access-token=$JFROG_TOKEN
# Archive and upload each artefact that we need, if folder are present.
- test -d opencti-platform/opencti-front/test-results && tar -czvf frontend-test-results-$DRONE_BUILD_NUMBER.tar.gz opencti-platform/opencti-front/test-results
- test -d opencti-platform/opencti-front/test-results && jf rt u frontend-test-results-$DRONE_BUILD_NUMBER.tar.gz $JFROG_REPOSITORY --build-name=$JFROG_BUILD_NAME --build-number=$DRONE_BUILD_NUMBER --url=$JFROG_URL --access-token=$JFROG_TOKEN
- test -d opencti-platform/opencti-graphql/test-results && tar -czvf backend-test-results-$DRONE_BUILD_NUMBER.tar.gz opencti-platform/opencti-graphql/test-results
- test -d opencti-platform/opencti-graphql/test-results && jf rt u backend-test-results-$DRONE_BUILD_NUMBER.tar.gz $JFROG_REPOSITORY --build-name=$JFROG_BUILD_NAME --build-number=$DRONE_BUILD_NUMBER --url=$JFROG_URL --access-token=$JFROG_TOKEN
# Next line should be done only once at the end: it's recording and gathering build info
- jf rt bp $JFROG_BUILD_NAME $DRONE_BUILD_NUMBER --url=$JFROG_URL --access-token=$JFROG_TOKEN --build-url=$DRONE_BUILD_LINK
# Cleaning up old build in JFrog
Expand Down

0 comments on commit 0d2a3f8

Please sign in to comment.