Skip to content

Commit

Permalink
add artifact check to external trigger
Browse files Browse the repository at this point in the history
  • Loading branch information
aptalca committed Oct 8, 2024
1 parent 4ce426c commit 59b327c
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 11 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/external_trigger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,12 @@ jobs:
echo "New version \`${EXT_RELEASE}\` found; but there already seems to be an active build on Jenkins; exiting" >> $GITHUB_STEP_SUMMARY
exit 0
else
assets=$(curl -u "${{ secrets.CR_USER }}:${{ secrets.CR_PAT }}" -sX GET "https://api.github.com/repos/VSCodium/vscodium/releases/tags/${EXT_RELEASE}" | jq -r '.assets[].browser_download_url')
if grep -q "codium_${EXT_RELEASE}_amd64.deb$" <<< "${assets}"; then
artifacts_found="true"
else
artifacts_found="false"
fi
if [[ "${artifacts_found}" == "false" ]]; then
echo "> [!WARNING]" >> $GITHUB_STEP_SUMMARY
echo "> New version detected, but not all artifacts are published yet; skipping trigger" >> $GITHUB_STEP_SUMMARY
Expand Down
3 changes: 3 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# syntax=docker/dockerfile:1

FROM ghcr.io/linuxserver/baseimage-kasmvnc:debianbookworm

# set version label
Expand Down Expand Up @@ -38,6 +40,7 @@ RUN \
mv \
/usr/bin/chromium \
/usr/bin/chromium-real && \
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
echo "**** cleanup ****" && \
apt-get autoclean && \
rm -rf \
Expand Down
3 changes: 3 additions & 0 deletions Dockerfile.aarch64
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# syntax=docker/dockerfile:1

FROM ghcr.io/linuxserver/baseimage-kasmvnc:arm64v8-debianbookworm

# set version label
Expand Down Expand Up @@ -38,6 +40,7 @@ RUN \
mv \
/usr/bin/chromium \
/usr/bin/chromium-real && \
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
echo "**** cleanup ****" && \
apt-get autoclean && \
rm -rf \
Expand Down
4 changes: 2 additions & 2 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ pipeline {
CI_PORT = '3000'
CI_SSL = 'false'
CI_DELAY = '120'
CI_DOCKERENV = 'TZ=US/Pacific'
CI_AUTH = 'user:password'
CI_DOCKERENV = ''
CI_AUTH = ''
CI_WEBPATH = ''
}
stages {
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ services:
- PGID=1000
- TZ=Etc/UTC
volumes:
- /path/to/config:/config
- /path/to/vscodium/config:/config
ports:
- 3000:3000
- 3001:3001
Expand All @@ -152,7 +152,7 @@ docker run -d \
-e TZ=Etc/UTC \
-p 3000:3000 \
-p 3001:3001 \
-v /path/to/config:/config \
-v /path/to/vscodium/config:/config \
--shm-size="1gb" \
--restart unless-stopped \
lscr.io/linuxserver/vscodium:latest
Expand Down
12 changes: 9 additions & 3 deletions jenkins-vars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,13 @@ external_type: github_stable
release_type: stable
release_tag: latest
ls_branch: master
build_armhf: false
external_artifact_check: |
assets=$(curl -u "${{ '{{' }} secrets.CR_USER {{ '}}' }}:${{ '{{' }} secrets.CR_PAT {{ '}}' }}" -sX GET "https://api.github.com/repos/VSCodium/vscodium/releases/tags/${EXT_RELEASE}" | jq -r '.assets[].browser_download_url')
if grep -q "codium_${EXT_RELEASE}_amd64.deb$" <<< "${assets}"; then
artifacts_found="true"
else
artifacts_found="false"
fi
repo_vars:
- EXT_GIT_BRANCH = 'master'
- EXT_USER = 'VSCodium'
Expand All @@ -25,6 +31,6 @@ repo_vars:
- CI_PORT = '3000'
- CI_SSL = 'false'
- CI_DELAY = '120'
- CI_DOCKERENV = 'TZ=US/Pacific'
- CI_AUTH = 'user:password'
- CI_DOCKERENV = ''
- CI_AUTH = ''
- CI_WEBPATH = ''
5 changes: 1 addition & 4 deletions readme-vars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,9 @@ development_versions: false
# container parameters
common_param_env_vars_enabled: true
param_container_name: "{{ project_name }}"
param_usage_include_env: true
param_env_vars:
- { env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use EG Europe/London." }
param_usage_include_vols: true
param_volumes:
- { vol_path: "/config", vol_host_path: "/path/to/config", desc: "Users home directory in the container, stores local files and settings" }
- { vol_path: "/config", vol_host_path: "/path/to/{{ project_name }}/config", desc: "Users home directory in the container, stores local files and settings" }
param_usage_include_ports: true
param_ports:
- { external_port: "3000", internal_port: "3000", port_desc: "VSCodium desktop gui." }
Expand Down

0 comments on commit 59b327c

Please sign in to comment.