diff --git a/.github/workflows/external_trigger.yml b/.github/workflows/external_trigger.yml index fc65325..358a0e8 100755 --- a/.github/workflows/external_trigger.yml +++ b/.github/workflows/external_trigger.yml @@ -20,7 +20,7 @@ jobs: echo "**** External trigger running off of master branch. To disable this trigger, set a Github secret named \"PAUSE_EXTERNAL_TRIGGER_OPENSSH_SERVER_MASTER\". ****" echo "External trigger running off of master branch. To disable this trigger, set a Github secret named \`PAUSE_EXTERNAL_TRIGGER_OPENSSH_SERVER_MASTER\`" >> $GITHUB_STEP_SUMMARY echo "**** Retrieving external version ****" - EXT_RELEASE=$(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.19/main/x86_64/APKINDEX.tar.gz" | tar -xz -C /tmp \ + EXT_RELEASE=$(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.20/main/x86_64/APKINDEX.tar.gz" | tar -xz -C /tmp \ && awk '/^P:'"openssh-server-pam"'$/,/V:/' /tmp/APKINDEX | sed -n 2p | sed 's/^V://') if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then echo "**** Can't retrieve external version, exiting ****" @@ -74,7 +74,7 @@ jobs: echo "**** Version ${EXT_RELEASE} already pushed, exiting ****" echo "Version ${EXT_RELEASE} already pushed, exiting" >> $GITHUB_STEP_SUMMARY exit 0 - elif [[ $(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.19/main/aarch64/APKINDEX.tar.gz" | tar -xz -C /tmp && awk '/^P:'"openssh-server-pam"'$/,/V:/' /tmp/APKINDEX | sed -n 2p | sed 's/^V://') != "${EXT_RELEASE}" ]]; then + elif [[ $(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.20/main/aarch64/APKINDEX.tar.gz" | tar -xz -C /tmp && awk '/^P:'"openssh-server-pam"'$/,/V:/' /tmp/APKINDEX | sed -n 2p | sed 's/^V://') != "${EXT_RELEASE}" ]]; then echo "**** New version ${EXT_RELEASE} found; but not all arch repos updated yet; exiting ****" echo "New version ${EXT_RELEASE} found; but not all arch repos updated yet; exiting" >> $GITHUB_STEP_SUMMARY FAILURE_REASON="New version ${EXT_RELEASE} for openssh-server tag latest is detected, however not all arch repos are updated yet. Will try again later." diff --git a/Dockerfile b/Dockerfile index 77a562d..f4d4707 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # syntax=docker/dockerfile:1 -FROM ghcr.io/linuxserver/baseimage-alpine:3.19 +FROM ghcr.io/linuxserver/baseimage-alpine:3.20 # set version label ARG BUILD_DATE @@ -18,13 +18,14 @@ RUN \ sudo && \ echo "**** install openssh-server ****" && \ if [ -z ${OPENSSH_RELEASE+x} ]; then \ - OPENSSH_RELEASE=$(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.19/main/x86_64/APKINDEX.tar.gz" | tar -xz -C /tmp && \ + OPENSSH_RELEASE=$(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.20/main/x86_64/APKINDEX.tar.gz" | tar -xz -C /tmp && \ awk '/^P:openssh-server-pam$/,/V:/' /tmp/APKINDEX | sed -n 2p | sed 's/^V://'); \ fi && \ apk add --no-cache \ openssh-client==${OPENSSH_RELEASE} \ openssh-server-pam==${OPENSSH_RELEASE} \ openssh-sftp-server==${OPENSSH_RELEASE} && \ + printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \ echo "**** setup openssh environment ****" && \ sed -i 's/#PasswordAuthentication yes/PasswordAuthentication no/g' /etc/ssh/sshd_config && \ usermod --shell /bin/bash abc && \ diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index a506670..b1f528b 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -1,6 +1,6 @@ # syntax=docker/dockerfile:1 -FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.19 +FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.20 # set version label ARG BUILD_DATE @@ -18,13 +18,14 @@ RUN \ sudo && \ echo "**** install openssh-server ****" && \ if [ -z ${OPENSSH_RELEASE+x} ]; then \ - OPENSSH_RELEASE=$(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.19/main/aarch64/APKINDEX.tar.gz" | tar -xz -C /tmp && \ + OPENSSH_RELEASE=$(curl -sL "http://dl-cdn.alpinelinux.org/alpine/v3.20/main/aarch64/APKINDEX.tar.gz" | tar -xz -C /tmp && \ awk '/^P:openssh-server-pam$/,/V:/' /tmp/APKINDEX | sed -n 2p | sed 's/^V://'); \ fi && \ apk add --no-cache \ openssh-client==${OPENSSH_RELEASE} \ openssh-server-pam==${OPENSSH_RELEASE} \ openssh-sftp-server==${OPENSSH_RELEASE} && \ + printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \ echo "**** setup openssh environment ****" && \ sed -i 's/#PasswordAuthentication yes/PasswordAuthentication no/g' /etc/ssh/sshd_config && \ usermod --shell /bin/bash abc && \ diff --git a/Jenkinsfile b/Jenkinsfile index aba0d7b..b4ed935 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -26,7 +26,7 @@ pipeline { PR_DOCKERHUB_IMAGE = 'lspipepr/openssh-server' DIST_IMAGE = 'alpine' DIST_TAG = '3.18' - DIST_REPO = 'http://dl-cdn.alpinelinux.org/alpine/v3.19/main/' + DIST_REPO = 'http://dl-cdn.alpinelinux.org/alpine/v3.20/main/' DIST_REPO_PACKAGES = 'openssh-server-pam' MULTIARCH='true' CI='true' @@ -34,8 +34,8 @@ pipeline { CI_PORT='80' CI_SSL='false' CI_DELAY='60' - CI_DOCKERENV='TZ=US/Pacific' - CI_AUTH='user:password' + CI_DOCKERENV='' + CI_AUTH='' CI_WEBPATH='' } stages { diff --git a/README.md b/README.md index 77f8729..0976d98 100644 --- a/README.md +++ b/README.md @@ -121,7 +121,7 @@ services: - USER_NAME=linuxserver.io #optional - LOG_STDOUT= #optional volumes: - - /path/to/appdata/config:/config + - /path/to/openssh-server/config:/config ports: - 2222:2222 restart: unless-stopped @@ -147,7 +147,7 @@ docker run -d \ -e USER_NAME=linuxserver.io `#optional` \ -e LOG_STDOUT= `#optional` \ -p 2222:2222 \ - -v /path/to/appdata/config:/config \ + -v /path/to/openssh-server/config:/config \ --restart unless-stopped \ lscr.io/linuxserver/openssh-server:latest ``` @@ -336,6 +336,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64 ## Versions +* **31.05.24:** - Rebase to Alpine 3.20. * **04.05.24:** - Display the SSH host public keys every time the container starts. * **09.03.24:** - Rebase to Alpine 3.19. * **12.06.23:** - Rebase to Alpine 3.18, deprecate armhf. As announced [here](https://www.linuxserver.io/blog/a-farewell-to-arm-hf) diff --git a/jenkins-vars.yml b/jenkins-vars.yml index 343a8be..11b8a72 100644 --- a/jenkins-vars.yml +++ b/jenkins-vars.yml @@ -6,7 +6,6 @@ external_type: alpine_repo release_type: stable release_tag: latest ls_branch: master -build_armhf: false repo_vars: - CONTAINER_NAME = 'openssh-server' - BUILD_VERSION_ARG = 'OPENSSH_RELEASE' @@ -17,7 +16,7 @@ repo_vars: - PR_DOCKERHUB_IMAGE = 'lspipepr/openssh-server' - DIST_IMAGE = 'alpine' - DIST_TAG = '3.18' - - DIST_REPO = 'http://dl-cdn.alpinelinux.org/alpine/v3.19/main/' + - DIST_REPO = 'http://dl-cdn.alpinelinux.org/alpine/v3.20/main/' - DIST_REPO_PACKAGES = 'openssh-server-pam' - MULTIARCH='true' - CI='true' @@ -25,6 +24,6 @@ repo_vars: - CI_PORT='80' - CI_SSL='false' - CI_DELAY='60' - - CI_DOCKERENV='TZ=US/Pacific' - - CI_AUTH='user:password' + - CI_DOCKERENV='' + - CI_AUTH='' - CI_WEBPATH='' diff --git a/readme-vars.yml b/readme-vars.yml index a5844fd..240df5b 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -10,8 +10,7 @@ project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_ available_architectures: - {arch: "{{ arch_x86_64 }}", tag: "amd64-latest"} - {arch: "{{ arch_arm64 }}", tag: "arm64v8-latest"} -# development version -development_versions: false + # container parameters common_param_env_vars_enabled: true param_container_name: "{{ project_name }}" @@ -20,13 +19,10 @@ param_hostname: "{{ project_name }}" param_hostname_desc: "Optionally the hostname can be defined." param_usage_include_vols: true param_volumes: - - {vol_path: "/config", vol_host_path: "/path/to/appdata/config", desc: "Contains all relevant configuration files."} + - {vol_path: "/config", vol_host_path: "/path/to/{{ project_name }}/config", desc: "Contains all relevant configuration files."} param_usage_include_ports: true param_ports: - {external_port: "2222", internal_port: "2222", port_desc: "ssh port"} -param_usage_include_env: true -param_env_vars: - - {env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use EG Europe/London"} # optional container parameters opt_param_usage_include_env: true opt_param_env_vars: @@ -76,6 +72,7 @@ app_setup_block: | The keys generated by this script are only displayed on your console output, so make sure to save them somewhere after generation. # changelog changelogs: + - {date: "31.05.24:", desc: "Rebase to Alpine 3.20."} - {date: "04.05.24:", desc: "Display the SSH host public keys every time the container starts."} - {date: "09.03.24:", desc: "Rebase to Alpine 3.19."} - {date: "12.06.23:", desc: "Rebase to Alpine 3.18, deprecate armhf. As announced [here](https://www.linuxserver.io/blog/a-farewell-to-arm-hf)"} diff --git a/root/etc/s6-overlay/s6-rc.d/init-adduser/run b/root/etc/s6-overlay/s6-rc.d/init-adduser/run index 3c366f5..efe470e 100755 --- a/root/etc/s6-overlay/s6-rc.d/init-adduser/run +++ b/root/etc/s6-overlay/s6-rc.d/init-adduser/run @@ -31,21 +31,12 @@ GID/UID echo " User UID: $(id -u "${USER_NAME}") User GID: $(id -g "${USER_NAME}") -─────────────────────────────────────── -" - -if [[ "$(uname -m)" == "armv7l" ]] || [[ "$(uname -m)" == "armhf" ]]; then +───────────────────────────────────────" +if [[ -f /build_version ]]; then + cat /build_version echo ' -╔═════════════════════════════════════════════════════╗ -║ ║ -║ The 32-bit Arm version of this image will ║ -║ no longer be supported after 2023-07-01 ║ -║ ║ -║ See: https://linuxserver.io/armhf ║ -║ for more details ║ -║ ║ -╚═════════════════════════════════════════════════════╝ -' +─────────────────────────────────────── + ' fi lsiown "${USER_NAME}":"${USER_NAME}" /app