From 6233e3e17069ff8e803e3479f954ed1c0afcf84a Mon Sep 17 00:00:00 2001 From: Michael Hollister Date: Mon, 17 Feb 2025 12:45:39 -0600 Subject: [PATCH] Added Gitlab runner CI support for Tizen builds --- .gitlab-ci.yml | 1 + receivers/tizen/.gitlab-ci.yml | 34 ++++++++++++++++++++++++++++++++ receivers/tizen/scripts/build.sh | 12 +++++------ 3 files changed, 41 insertions(+), 6 deletions(-) create mode 100644 receivers/tizen/.gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index b4468ad..7fa3c0d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,3 +16,4 @@ include: - local: 'receivers/android/.gitlab-ci.yml' - local: 'receivers/electron/.gitlab-ci.yml' - local: 'receivers/webos/.gitlab-ci.yml' + - local: 'receivers/tizen/.gitlab-ci.yml' diff --git a/receivers/tizen/.gitlab-ci.yml b/receivers/tizen/.gitlab-ci.yml new file mode 100644 index 0000000..cee38ac --- /dev/null +++ b/receivers/tizen/.gitlab-ci.yml @@ -0,0 +1,34 @@ + +buildTizenOSDockerContainer: + stage: buildDockerContainers + image: docker:20.10.16 + services: + - docker:20.10.16-dind + tags: + - fcast-instance-runner + before_script: + - cd receivers/tizen + script: + - echo "$CI_REGISTRY_PASSWORD" | docker login $CI_REGISTRY -u $CI_REGISTRY_USER --password-stdin + - docker build -t $CI_REGISTRY/videostreaming/fcast/receiver-tizen-dev:latest . + - docker push $CI_REGISTRY/videostreaming/fcast/receiver-tizen-dev:latest + when: manual + +buildTizenOSReceiver: + stage: buildTizenOSReceiver + image: gitlab.futo.org:5050/videostreaming/fcast/receiver-tizen-dev:latest + tags: + - fcast-instance-runner + before_script: + - cd receivers/tizen + script: + - npm install + - scripts/build.sh + artifacts: + untracked: false + when: on_success + access: all + expire_in: "30 days" + paths: + - receivers/tizen/FCastReceiver/.buildResult/FCastReceiver.wgt + when: manual diff --git a/receivers/tizen/scripts/build.sh b/receivers/tizen/scripts/build.sh index 625f533..eb44b46 100755 --- a/receivers/tizen/scripts/build.sh +++ b/receivers/tizen/scripts/build.sh @@ -15,16 +15,16 @@ cd .buildResult # it has to be regenerated on every packaging... # https://stackoverflow.com/a/61718469 -tizen security-profiles add --active --force --name default --author /home/ubuntu/author/default/author.p12 --password $CERT_AUTHOR_PASSWORD --dist /home/ubuntu/SamsungCertificate/default/distributor.p12 --dist-password $CERT_DIST_PASSWORD +tizen security-profiles add --active --force --name default --author $CERT_PATH/author/default/author.p12 --password $CERT_AUTHOR_PASSWORD --dist $CERT_PATH/SamsungCertificate/default/distributor.p12 --dist-password $CERT_DIST_PASSWORD tizen cli-config "profiles.path=/home/ubuntu/tizen-studio-data/profile/profiles.xml" -sed -i "s/\/home\/ubuntu\/author\/default\/author.pwd/$CERT_AUTHOR_PASSWORD/g" /home/ubuntu/tizen-studio-data/profile/profiles.xml -sed -i "s/\/home\/ubuntu\/SamsungCertificate\/default\/distributor.pwd/$CERT_DIST_PASSWORD/g" /home/ubuntu/tizen-studio-data/profile/profiles.xml +sed -i "s/$CERT_PATH\/author\/default\/author.pwd/$CERT_AUTHOR_PASSWORD/g" /home/ubuntu/tizen-studio-data/profile/profiles.xml +sed -i "s/$CERT_PATH\/SamsungCertificate\/default\/distributor.pwd/$CERT_DIST_PASSWORD/g" /home/ubuntu/tizen-studio-data/profile/profiles.xml ../../scripts/package.sh tizen package -t wgt -s default -- . -tizen security-profiles add --active --force --name default --author /home/ubuntu/author/default/author.p12 --password $CERT_AUTHOR_PASSWORD --dist /home/ubuntu/SamsungCertificate/default/distributor.p12 --dist-password $CERT_DIST_PASSWORD +tizen security-profiles add --active --force --name default --author $CERT_PATH/author/default/author.p12 --password $CERT_AUTHOR_PASSWORD --dist $CERT_PATH/SamsungCertificate/default/distributor.p12 --dist-password $CERT_DIST_PASSWORD tizen cli-config "profiles.path=/home/ubuntu/tizen-studio-data/profile/profiles.xml" -sed -i "s/\/home\/ubuntu\/author\/default\/author.pwd/$CERT_AUTHOR_PASSWORD/g" /home/ubuntu/tizen-studio-data/profile/profiles.xml -sed -i "s/\/home\/ubuntu\/SamsungCertificate\/default\/distributor.pwd/$CERT_DIST_PASSWORD/g" /home/ubuntu/tizen-studio-data/profile/profiles.xml +sed -i "s/$CERT_PATH\/author\/default\/author.pwd/$CERT_AUTHOR_PASSWORD/g" /home/ubuntu/tizen-studio-data/profile/profiles.xml +sed -i "s/$CERT_PATH\/SamsungCertificate\/default\/distributor.pwd/$CERT_DIST_PASSWORD/g" /home/ubuntu/tizen-studio-data/profile/profiles.xml ../../scripts/package.sh tizen package -t wgt -s default -r ../../FCastReceiverService/bin/Release/netcoreapp2.1/com.futo.FCastReceiverService-1.0.0.tpk -- FCastReceiver.wgt cd ../../