diff --git a/Jenkinsfile b/Jenkinsfile index d40fb4a..5fa1349 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -101,21 +101,21 @@ pipeline { /* ######################## External Release Tagging ######################## */ - // If this is a stable github release use the latest endpoint from github to determine the ext tag - stage("Set ENV github_stable"){ + // If this is a github commit trigger determine the current commit at head + stage("Set ENV github_commit"){ steps{ script{ env.EXT_RELEASE = sh( - script: '''curl -s https://api.github.com/repos/${EXT_USER}/${EXT_REPO}/releases/latest | jq -r '. | .tag_name' ''', + script: '''curl -s https://api.github.com/repos/${EXT_USER}/${EXT_REPO}/commits/${EXT_GIT_BRANCH} | jq -r '. | .sha' | cut -c1-8 ''', returnStdout: true).trim() } } } - // If this is a stable or devel github release generate the link for the build message - stage("Set ENV github_link"){ + // If this is a github commit trigger Set the external release link + stage("Set ENV commit_link"){ steps{ script{ - env.RELEASE_LINK = 'https://github.com/' + env.EXT_USER + '/' + env.EXT_REPO + '/releases/tag/' + env.EXT_RELEASE + env.RELEASE_LINK = 'https://github.com/' + env.EXT_USER + '/' + env.EXT_REPO + '/commit/' + env.EXT_RELEASE } } } @@ -672,7 +672,7 @@ pipeline { "tagger": {"name": "LinuxServer Jenkins","email": "jenkins@linuxserver.io","date": "'${GITHUB_DATE}'"}}' ''' echo "Pushing New release for Tag" sh '''#! /bin/bash - curl -s https://api.github.com/repos/${EXT_USER}/${EXT_REPO}/releases/latest | jq '. |.body' | sed 's:^.\\(.*\\).$:\\1:' > releasebody.json + curl -s https://api.github.com/repos/${EXT_USER}/${EXT_REPO}/commits/${EXT_GIT_BRANCH} | jq '. | .commit.message' | sed 's:^.\\(.*\\).$:\\1:' > releasebody.json echo '{"tag_name":"'${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}'",\ "target_commitish": "master",\ "name": "'${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}'",\ diff --git a/README.md b/README.md index bd937f1..a4764e4 100644 --- a/README.md +++ b/README.md @@ -37,7 +37,7 @@ Find us at: [Snapdrop](https://github.com/RobinLinus/snapdrop) A local file sharing in your browser. Inspired by Apple's Airdrop. -[![snapdrop]()](https://github.com/RobinLinus/snapdrop) +[![snapdrop](https://raw.githubusercontent.com/RobinLinus/snapdrop/master/client/images/logo_transparent_512x512.png)](https://github.com/RobinLinus/snapdrop) ## Supported Architectures @@ -68,6 +68,7 @@ docker create \ -e TZ=Europe/London \ -p 80:80 \ -p 443:443 \ + -v :/config \ --restart unless-stopped \ linuxserver/snapdrop ``` @@ -88,6 +89,8 @@ services: - PUID=1000 - PGID=1000 - TZ=Europe/London + volumes: + - :/config ports: - 80:80 - 443:443 @@ -105,6 +108,7 @@ Container images are configured using parameters passed at runtime (such as thos | `-e PUID=1000` | for UserID - see below for explanation | | `-e PGID=1000` | for GroupID - see below for explanation | | `-e TZ=Europe/London` | Specify a timezone to use EG Europe/London. | +| `-v /config` | Persistent configs and logs. | ## Environment variables from files (Docker secrets) diff --git a/jenkins-vars.yml b/jenkins-vars.yml index d4124c0..fb6f048 100644 --- a/jenkins-vars.yml +++ b/jenkins-vars.yml @@ -2,7 +2,7 @@ # jenkins variables project_name: docker-snapdrop -external_type: github_stable +external_type: github_commit release_type: stable release_tag: latest ls_branch: master diff --git a/readme-vars.yml b/readme-vars.yml index 50a1abd..0960143 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -3,7 +3,7 @@ # project information project_name: snapdrop project_url: "https://github.com/RobinLinus/snapdrop" -project_logo: "" +project_logo: "https://raw.githubusercontent.com/RobinLinus/snapdrop/master/client/images/logo_transparent_512x512.png" project_blurb: "[{{ project_name|capitalize }}]({{ project_url }}) A local file sharing in your browser. Inspired by Apple's Airdrop." project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_name }}" @@ -30,6 +30,10 @@ 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: "", desc: "Persistent configs and logs." } + param_usage_include_ports: true param_ports: - { external_port: "80", internal_port: "80", port_desc: "http gui" }