Next release WIP #

This commit is contained in:
Darren Clarke 2025-10-27 21:02:19 +01:00
parent 7d7944fa90
commit 20078ccacc
10 changed files with 219 additions and 94 deletions

View file

@ -38,15 +38,14 @@ RUN bundle check || bundle install --jobs 8
# Install Node packages
RUN pnpm install --frozen-lockfile
# CRITICAL: Install addons BEFORE asset compilation
# This extracts addon files including Vue components, TypeScript, and CSS
# CRITICAL: Install addons
# This extracts addon files including CoffeeScript, Vue components, TypeScript, and CSS
RUN ruby contrib/link/install.rb
# Recompile assets with our addon components
# The base image has assets precompiled, but we need to recompile with our additions
# SKIP asset compilation during build - it will happen at runtime via entrypoint
# This is because asset compilation requires Redis which isn't available during build
# RUN bundle exec rake assets:precompile RAILS_SKIP_ASSET_COMPILATION=false || echo "Skipped"
# Precompile assets with addon CoffeeScript files included
# Use ZAMMAD_SAFE_MODE=1 and dummy DATABASE_URL to avoid needing real database
RUN touch db/schema.rb && \
ZAMMAD_SAFE_MODE=1 DATABASE_URL=postgresql://zammad:/zammad bundle exec rake assets:precompile
# Run additional setup for addons
RUN bundle exec rails runner /opt/zammad/contrib/link/setup.rb || true
@ -69,14 +68,6 @@ RUN if [ "$EMBEDDED" = "true" ] ; then \
echo " }" >> /opt/zammad/contrib/nginx/zammad.conf && \
echo "}" >> /opt/zammad/contrib/nginx/zammad.conf; \
fi
RUN sed -i '/^[[:space:]]*# es config/a\
echo "about to reinstall..."\n\
bundle exec rails runner /opt/zammad/contrib/link/setup.rb\n\
bundle exec rake zammad:package:migrate\n\
echo "Recompiling assets with addon CoffeeScript files..."\n\
bundle exec rake assets:precompile RAILS_SKIP_ASSET_COMPILATION=false\n\
echo "Asset recompilation complete"\n\
' /docker-entrypoint.sh
FROM zammad/zammad-docker-compose:${ZAMMAD_VERSION} AS runner
USER root