diff --git a/.app_version b/.app_version index 12a91df0..5564d9ac 100644 --- a/.app_version +++ b/.app_version @@ -1 +1 @@ -0.26.4 +0.26.5 diff --git a/CHANGELOG.md b/CHANGELOG.md index f0786ace..c9b5c904 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). +# 0.26.5 - 2025-05-20 + +## Fixed + +- Wget is back to fix healthchecks. #1241 #1231 +- Dockerfile.prod is now using slim image. #1245 +- Dockerfiles now use jemalloc with check for architecture. #1235 + # 0.26.4 - 2025-05-19 ## Changed diff --git a/app/jobs/data_migrations/set_points_country_ids_job.rb b/app/jobs/data_migrations/set_points_country_ids_job.rb index 1ca9ac42..42918c22 100644 --- a/app/jobs/data_migrations/set_points_country_ids_job.rb +++ b/app/jobs/data_migrations/set_points_country_ids_job.rb @@ -5,7 +5,13 @@ class DataMigrations::SetPointsCountryIdsJob < ApplicationJob def perform(point_id) point = Point.find(point_id) - point.country_id = Country.containing_point(point.lon, point.lat).id - point.save! + country = Country.containing_point(point.lon, point.lat) + + if country.present? + point.country_id = country.id + point.save! + else + Rails.logger.info("No country found for point #{point.id}") + end end end diff --git a/docker/Dockerfile.dev b/docker/Dockerfile.dev index 849938f5..2bb8c3a4 100644 --- a/docker/Dockerfile.dev +++ b/docker/Dockerfile.dev @@ -11,6 +11,7 @@ ENV SIDEKIQ_USERNAME=sidekiq ENV SIDEKIQ_PASSWORD=password RUN apt-get update -qq && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \ + wget \ build-essential \ git \ postgresql-client \ @@ -28,8 +29,12 @@ RUN apt-get update -qq && DEBIAN_FRONTEND=noninteractive apt-get install -y --no && mkdir -p $APP_PATH \ && rm -rf /var/lib/apt/lists/* -# Use jemalloc -ENV LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libjemalloc.so.2 +# Use jemalloc with check for architecture +RUN if [ "$(uname -m)" = "x86_64" ]; then \ + echo "/usr/lib/x86_64-linux-gnu/libjemalloc.so.2" > /etc/ld.so.preload; \ + else \ + echo "/usr/lib/aarch64-linux-gnu/libjemalloc.so.2" > /etc/ld.so.preload; \ + fi # Optional: Set YJIT explicitly (enabled by default in 3.4.1 MRI builds) ENV RUBY_YJIT_ENABLE=1 diff --git a/docker/Dockerfile.prod b/docker/Dockerfile.prod index f6e1f568..c8830f62 100644 --- a/docker/Dockerfile.prod +++ b/docker/Dockerfile.prod @@ -1,4 +1,4 @@ -FROM ruby:3.4.1-alpine +FROM ruby:3.4.1-slim ENV APP_PATH=/var/app ENV BUNDLE_VERSION=2.5.21 @@ -25,8 +25,12 @@ RUN apt-get update -qq && DEBIAN_FRONTEND=noninteractive apt-get install -y --no && mkdir -p $APP_PATH \ && rm -rf /var/lib/apt/lists/* -# Use jemalloc -ENV LD_PRELOAD=/usr/lib/libjemalloc.so.2 +# Use jemalloc with check for architecture +RUN if [ "$(uname -m)" = "x86_64" ]; then \ + echo "/usr/lib/x86_64-linux-gnu/libjemalloc.so.2" > /etc/ld.so.preload; \ + else \ + echo "/usr/lib/aarch64-linux-gnu/libjemalloc.so.2" > /etc/ld.so.preload; \ + fi # Enable YJIT ENV RUBY_YJIT_ENABLE=1