Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rebase to 3.20, symlink robots.txt to /config #46

Merged
merged 2 commits into from
Jun 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# syntax=docker/dockerfile:1

FROM ghcr.io/linuxserver/baseimage-alpine-nginx:3.19
FROM ghcr.io/linuxserver/baseimage-alpine-nginx:3.20

ARG BUILD_DATE
ARG VERSION
Expand Down Expand Up @@ -47,6 +47,7 @@ RUN \
unzip -q \
/tmp/grav.zip -d /tmp/grav && \
mv /tmp/grav/grav-admin/* /app/www/public/ && \
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
echo "**** cleanup ****" && \
rm -rf \
/tmp/* \
Expand Down
3 changes: 2 additions & 1 deletion Dockerfile.aarch64
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# syntax=docker/dockerfile:1

FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm64v8-3.19
FROM ghcr.io/linuxserver/baseimage-alpine-nginx:arm64v8-3.20

ARG BUILD_DATE
ARG VERSION
Expand Down Expand Up @@ -47,6 +47,7 @@ RUN \
unzip -q \
/tmp/grav.zip -d /tmp/grav && \
mv /tmp/grav/grav-admin/* /app/www/public/ && \
printf "Linuxserver.io version: ${VERSION}\nBuild-date: ${BUILD_DATE}" > /build_version && \
echo "**** cleanup ****" && \
rm -rf \
/tmp/* \
Expand Down
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ pipeline {
CI_PORT='80'
CI_SSL='false'
CI_DELAY='120'
CI_DOCKERENV='TZ=US/Pacific'
CI_DOCKERENV=''
CI_AUTH=''
CI_WEBPATH=''
}
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64

## Versions

* **19.06.24:** - Rebase to Alpine 3.20. Symlink robots.txt to /config. Existing users should update their nginx confs to avoid http2 deprecation warnings.
* **06.03.24:** - Add brotli to nginx.
* **06.03.24:** - Existing users should update: site-confs/default.conf - Cleanup default site conf.
* **23.12.23:** - Rebase to Alpine 3.19 with php 8.3.
Expand Down
4 changes: 1 addition & 3 deletions jenkins-vars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ external_type: github_stable
release_type: stable
release_tag: latest
ls_branch: main
build_armhf: false
repo_vars:
- EXT_GIT_BRANCH = 'master'
- EXT_USER = 'getgrav'
Expand All @@ -25,10 +24,9 @@ repo_vars:
- CI_PORT='80'
- CI_SSL='false'
- CI_DELAY='120'
- CI_DOCKERENV='TZ=US/Pacific'
- CI_DOCKERENV=''
- CI_AUTH=''
- CI_WEBPATH=''

sponsor_links:
- { name: "Grav", url: "https://opencollective.com/grav/donate" }

5 changes: 1 addition & 4 deletions readme-vars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@ available_architectures:
common_param_env_vars_enabled: true
param_container_name: "{{ project_name }}"

param_usage_include_env: true
param_env_vars:
- { env_var: "TZ", env_value: "America/New_York", desc: "Specify a timezone to use EG America/New_York"}

param_usage_include_ports: true
param_ports:
- { external_port: "80", internal_port: "80", port_desc: "Port for web frontend" }
Expand All @@ -39,6 +35,7 @@ app_setup_block: |

# changelog
changelogs:
- { date: "19.06.24:", desc: "Rebase to Alpine 3.20. Symlink robots.txt to /config. Existing users should update their nginx confs to avoid http2 deprecation warnings." }
- { date: "06.03.24:", desc: "Add brotli to nginx." }
- { date: "06.03.24:", desc: "Existing users should update: site-confs/default.conf - Cleanup default site conf." }
- { date: "23.12.23:", desc: "Rebase to Alpine 3.19 with php 8.3."}
Expand Down
9 changes: 3 additions & 6 deletions root/defaults/nginx/site-confs/default.conf.sample
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
## Version 2024/03/06 - Changelog: https://github.com/linuxserver/docker-grav/commits/main/root/defaults/nginx/site-confs/default.conf.sample
## Version 2024/06/19 - Changelog: https://github.com/linuxserver/docker-grav/commits/main/root/defaults/nginx/site-confs/default.conf.sample

server {
listen 80 default_server;
listen [::]:80 default_server;

listen 443 ssl http2 default_server;
listen [::]:443 ssl http2 default_server;
listen *:80 default_server;
listen *:443 ssl default_server;

server_name _;

Expand Down
20 changes: 20 additions & 0 deletions root/etc/s6-overlay/s6-rc.d/init-grav-config/run
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#!/usr/bin/with-contenv bash
# shellcheck shell=bash

# Symlink directories
symlinks=(
/app/www/public/backup
/app/www/public/logs
Expand All @@ -21,6 +22,25 @@ for i in "${symlinks[@]}"; do
fi
done

# Symlink files
symlinks=(
/app/www/public/robots.txt
)

shopt -s globstar dotglob

for i in "${symlinks[@]}"; do
if [[ -f /config/www/"$(basename "$i")" && ! -L "$i" ]]; then
rm -rf "$i"
fi
if [[ ! -f /config/www/"$(basename "$i")" && ! -L "$i" ]]; then
mv "$i" /config/www/
fi
if [[ -f /config/www/"$(basename "$i")" && ! -L "$i" ]]; then
ln -s /config/www/"$(basename "$i")" "$i"
fi
done

shopt -u globstar dotglob

sed -i 's/enable_auto_updates_check: true/enable_auto_updates_check: false/' /config/www/user/plugins/admin/admin.yaml
Expand Down