[action] add artifacts-ubuntu deb info
authorYelin Jeong <yelini.jeong@samsung.com>
Wed, 7 Dec 2022 01:36:43 +0000 (10:36 +0900)
committer추지호/NPU Lab(SR)/삼성전자 <jiho.chu@samsung.com>
Wed, 7 Dec 2022 01:58:08 +0000 (10:58 +0900)
This patch adds deb info to artifacts-ubuntu workflow.

Signed-off-by: Yelin Jeong <yelini.jeong@samsung.com>
.github/workflows/artifacts-ubuntu.yml

index b76dbffd17a9accba80665d79c6bf3192ad8667a..8210ada6093b47dc8946bede64da533901bff8ad 100644 (file)
@@ -34,14 +34,20 @@ jobs:
         with:
           name: debian packages for Bionic
           path: npu-engine*.deb
-      - name: Upload to artifactory
-        uses: ./.github/actions/upload-artifacts
-        with:
-          input_path: .
-          input_type: deb
-          art_repo: $BART_REPO/pool/bionic-nightly
-          art_id: $BART_ID
-          art_pw: $BART_PW
+      - name: Upload packages to Artifactory
+        shell: bash
+        run: |
+          for FILE in `find . -name "npu-engine*.deb" -type f -exec basename {} \;`; do \
+            curl \
+              --header "X-Checksum-MD5:`md5sum $FILE | awk '{ print $1 }'`" \
+              --header "X-Checksum-Sha1:`shasum -a 1 $FILE | awk '{ print $1 }'`" \
+              -u$BART_ID:$BART_PW \
+              -XPUT "$BART_REPO/pool/$DISTRO/$FILE;deb.distribution=$DISTRO;deb.component=universe;deb.architecture=amd64" \
+              -T $FILE \
+            ;\
+          done
+        env:
+          DISTRO: bionic-nightly
 
   upload-focal:
     # CODE-hosted runner
@@ -69,11 +75,17 @@ jobs:
         with:
           name: debian packages for Focal
           path: npu-engine*.deb
-      - name: Upload to artifactory
-        uses: ./.github/actions/upload-artifacts
-        with:
-          input_path: .
-          input_type: deb
-          art_repo: $BART_REPO/pool/focal-nightly
-          art_id: $BART_ID
-          art_pw: $BART_PW
+      - name: Upload packages to Artifactory
+        shell: bash
+        run: |
+          for FILE in `find . -name "npu-engine*.deb" -type f -exec basename {} \;`; do \
+            curl \
+              --header "X-Checksum-MD5:`md5sum $FILE | awk '{ print $1 }'`" \
+              --header "X-Checksum-Sha1:`shasum -a 1 $FILE | awk '{ print $1 }'`" \
+              -u$BART_ID:$BART_PW \
+              -XPUT "$BART_REPO/pool/$DISTRO/$FILE;deb.distribution=$DISTRO;deb.component=universe;deb.architecture=amd64" \
+              -T $FILE \
+            ;\
+          done
+        env:
+          DISTRO: focal-nightly