Skip to content

Commit

Permalink
Update Zammad patchlevel + dependencies and introduce updatecli (#422)
Browse files Browse the repository at this point in the history
  • Loading branch information
mgruner authored Jul 26, 2024
1 parent 0b1a832 commit 4656401
Show file tree
Hide file tree
Showing 3 changed files with 127 additions and 10 deletions.
10 changes: 5 additions & 5 deletions .env.dist
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
# ELASTICSEARCH_VERSION=8.12.2
# ELASTICSEARCH_VERSION=8.14.3
# IMAGE_REPO=ghcr.io/zammad/zammad
# MEMCACHE_SERVERS=zammad-memcached:11211
# MEMCACHE_VERSION=1.6.25-alpine
# MEMCACHE_VERSION=1.6.29-alpine
# NGINX_PORT=8080
# NGINX_EXPOSE_PORT=8080
# POSTGRES_DB=zammad_production
# POSTGRES_PASS=zammad
# POSTGRES_USER=zammad
# POSTGRES_HOST=zammad-postgresql
# POSTGRES_PORT=5432
# POSTGRES_VERSION=15.6-alpine
# POSTGRES_VERSION=15.7-alpine
# POSTGRESQL_OPTIONS=?pool=50
# REDIS_URL=redis://zammad-redis:6379
# REDIS_VERSION=7.2.4-alpine
# REDIS_VERSION=7.2.5-alpine
# RESTART=always
# Use a fixed version. You are responsible to update this to newer patch level versions yourself.
# VERSION=6.3.1-38
# VERSION=6.3.1-95
# You can also use floating versions that will give you automatic updates:
# VERSION=6.2 # all patchlevel updates
# VERSION=6 # including minor updates
Expand Down
117 changes: 117 additions & 0 deletions .github/updatecli.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
name: "Update Zammad version and dependency charts (patch and minor only)"

sources:
zammad:
kind: dockerimage
spec:
image: "zammad/zammad-docker-compose"
architecture: "linux/amd64"
tagfilter: "6\\.3.*"
elasticsearch:
kind: dockerimage
spec:
image: "bitnami/elasticsearch"
architecture: "linux/amd64"
versionfilter:
kind: "semver"
pattern: "8.x.x"
memcached:
kind: dockerimage
spec:
image: "memcached"
architecture: "linux/amd64"
versionfilter:
kind: "semver"
pattern: "1.6.x"
postgresql:
kind: dockerimage
spec:
image: "postgres"
architecture: "linux/amd64"
versionfilter:
kind: "semver"
pattern: "15.x.x"
redis:
kind: dockerimage
spec:
image: "redis"
architecture: "linux/amd64"
versionfilter:
kind: "semver"
pattern: "7.x.x"

conditions: {}

targets:
zammad:
# we can't use yaml because it breaks our file structure
kind: file
sourceid: zammad
spec:
file: docker-compose.yml
matchpattern: \${VERSION:-(.*)\}
replacepattern: ${VERSION:-{{ source `zammad` }}}
zammad-env-dist:
# we can't use yaml because it breaks our file structure
kind: file
sourceid: zammad
spec:
file: .env.dist
matchpattern: ' VERSION=(\d+\.\d+.\d+.*)'
replacepattern: ' VERSION={{ source `zammad` }}'
elasticsearch:
kind: file
sourceid: elasticsearch
spec:
file: docker-compose.yml
matchpattern: ELASTICSEARCH_VERSION:-(.*)\}
replacepattern: ELASTICSEARCH_VERSION:-{{ source `elasticsearch`}}}
elasticsearch-env-dist:
kind: file
sourceid: elasticsearch
spec:
file: .env.dist
matchpattern: ELASTICSEARCH_VERSION=(.*)
replacepattern: ELASTICSEARCH_VERSION={{ source `elasticsearch`}}
memcached:
kind: file
sourceid: memcached
spec:
file: docker-compose.yml
matchpattern: MEMCACHE_VERSION:-(.*)-alpine\}
replacepattern: MEMCACHE_VERSION:-{{ source `memcached` }}-alpine}
memcached-env-dist:
kind: file
sourceid: memcached
spec:
file: .env.dist
matchpattern: MEMCACHE_VERSION=(.*)-alpine
replacepattern: MEMCACHE_VERSION={{ source `memcached` }}-alpine
postgresql:
kind: file
sourceid: postgresql
spec:
file: docker-compose.yml
matchpattern: POSTGRES_VERSION:-(.*)-alpine\}
replacepattern: POSTGRES_VERSION:-{{ source `postgresql` }}-alpine}
postgresql-env-dist:
kind: file
sourceid: postgresql
spec:
file: .env.dist
matchpattern: POSTGRES_VERSION=(.*)-alpine
replacepattern: POSTGRES_VERSION={{ source `postgresql` }}-alpine
redis:
kind: file
sourceid: redis
spec:
file: docker-compose.yml
matchpattern: REDIS_VERSION:-(.*)-alpine\}
replacepattern: REDIS_VERSION:-{{ source `redis` }}-alpine}
redis-env-dist:
kind: file
sourceid: redis
spec:
file: .env.dist
matchpattern: REDIS_VERSION=(.*)-alpine
replacepattern: REDIS_VERSION={{ source `redis` }}-alpine
10 changes: 5 additions & 5 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ x-shared:
ZAMMAD_SESSION_JOBS:
ZAMMAD_PROCESS_SCHEDULED:
ZAMMAD_PROCESS_DELAYED_JOBS_WORKERS:
image: ${IMAGE_REPO:-ghcr.io/zammad/zammad}:${VERSION:-6.3.1-38}
image: ${IMAGE_REPO:-ghcr.io/zammad/zammad}:${VERSION:-6.3.1-95}
restart: ${RESTART:-always}
volumes:
- zammad-storage:/opt/zammad/storage
Expand All @@ -56,7 +56,7 @@ services:
user: 0:0

zammad-elasticsearch:
image: bitnami/elasticsearch:${ELASTICSEARCH_VERSION:-8.12.2}
image: bitnami/elasticsearch:${ELASTICSEARCH_VERSION:-8.14.3}
restart: ${RESTART:-always}
volumes:
- elasticsearch-data:/bitnami/elasticsearch/data
Expand All @@ -71,7 +71,7 @@ services:

zammad-memcached:
command: memcached -m 256M
image: memcached:${MEMCACHE_VERSION:-1.6.25-alpine}
image: memcached:${MEMCACHE_VERSION:-1.6.29-alpine}
restart: ${RESTART:-always}

zammad-nginx:
Expand All @@ -89,7 +89,7 @@ services:
POSTGRES_DB: ${POSTGRES_DB:-zammad_production}
POSTGRES_USER: ${POSTGRES_USER:-zammad}
POSTGRES_PASSWORD: ${POSTGRES_PASS:-zammad}
image: postgres:${POSTGRES_VERSION:-15.6-alpine}
image: postgres:${POSTGRES_VERSION:-15.7-alpine}
restart: ${RESTART:-always}
volumes:
- postgresql-data:/var/lib/postgresql/data
Expand All @@ -99,7 +99,7 @@ services:
command: ["zammad-railsserver"]

zammad-redis:
image: redis:${REDIS_VERSION:-7.2.4-alpine}
image: redis:${REDIS_VERSION:-7.2.5-alpine}
restart: ${RESTART:-always}
volumes:
- redis-data:/data
Expand Down

0 comments on commit 4656401

Please sign in to comment.