diff --git a/porting/manyfold/Dockerfile b/apps/manyfold/Dockerfile similarity index 92% rename from porting/manyfold/Dockerfile rename to apps/manyfold/Dockerfile index 76338d8b3..24f2e6ac4 100644 --- a/porting/manyfold/Dockerfile +++ b/apps/manyfold/Dockerfile @@ -1,4 +1,4 @@ -FROM ghcr.io/trueforge-org/node:22.22.0 +FROM ghcr.io/trueforge-org/node:24.15.0 ARG VERSION ARG TARGETARCH @@ -34,6 +34,7 @@ RUN \ libffi-dev \ libmariadb-dev \ libpq-dev \ + pkg-config \ ruby-dev \ libyaml-dev && \ echo "**** install manyfold ****" && \ @@ -64,6 +65,9 @@ RUN \ APP_VERSION=v${VERSION} \ bundle exec rake assets:precompile && \ rm db/schema.rb && \ + rm -rf /app/www/tmp /app/www/log && \ + ln -s /tmp/manyfold/tmp /app/www/tmp && \ + ln -s /tmp/manyfold/log /app/www/log && \ echo "**** cleanup ****" && \ yarn cache clean && \ apt-get purge -y --auto-remove \ @@ -71,6 +75,7 @@ RUN \ libffi-dev \ libmariadb-dev \ libpq-dev \ + pkg-config \ ruby-dev \ libyaml-dev && \ apt-get clean && \ diff --git a/apps/manyfold/container-test.yaml b/apps/manyfold/container-test.yaml new file mode 100644 index 000000000..045080551 --- /dev/null +++ b/apps/manyfold/container-test.yaml @@ -0,0 +1,8 @@ +# yaml-language-server: $schema=https://raw.githubusercontent.com/trueforge-org/forgetool/refs/heads/main/pkg/containers/test/container-test.schema.json + +# narrowed: requires external postgresql (opt_dependencies) and redis for sidekiq workers; +# full functional test not feasible in single-container suite +timeoutSeconds: 240 +filePaths: +- /app/www/vendor/bundle/ruby/3.3.0/bin/foreman +- /app/www/vendor/bundle/ruby/3.3.0/bin/bundle diff --git a/porting/manyfold/docker-bake.hcl b/apps/manyfold/docker-bake.hcl similarity index 100% rename from porting/manyfold/docker-bake.hcl rename to apps/manyfold/docker-bake.hcl diff --git a/porting/manyfold/root/generate-secret b/apps/manyfold/root/generate-secret similarity index 100% rename from porting/manyfold/root/generate-secret rename to apps/manyfold/root/generate-secret diff --git a/porting/manyfold/settings.yaml b/apps/manyfold/settings.yaml similarity index 100% rename from porting/manyfold/settings.yaml rename to apps/manyfold/settings.yaml diff --git a/porting/manyfold/start.sh b/apps/manyfold/start.sh similarity index 96% rename from porting/manyfold/start.sh rename to apps/manyfold/start.sh index 6e59b9b84..30ca83517 100755 --- a/porting/manyfold/start.sh +++ b/apps/manyfold/start.sh @@ -1,5 +1,8 @@ #!/usr/bin/env bash +# Create required runtime directories in /tmp +mkdir -p /tmp/manyfold/tmp /tmp/manyfold/log + # set secret key if unset SECRET_FILE="/config/secret_key_base.txt" if [[ -w /config ]]; then @@ -16,12 +19,11 @@ if [[ -w /config ]]; then fi printf "%s" "${SECRET_KEY_BASE}" > /var/run/s6/container_environment/SECRET_KEY_BASE - mkdir -p /app/www/log /app/www/tmp else # /config is readonly, use /tmp echo "Warning: /config is read-only, using /tmp for runtime data" SECRET_FILE="/tmp/manyfold/secret_key_base.txt" - mkdir -p /tmp/manyfold /app/www/log /app/www/tmp + mkdir -p /tmp/manyfold if [ -n "${SECRET_KEY_BASE}" ]; then echo "**** SECRET_KEY_BASE set in environment. ****" diff --git a/porting/manyfold/container-test.yaml b/porting/manyfold/container-test.yaml deleted file mode 100644 index 4d22f5b29..000000000 --- a/porting/manyfold/container-test.yaml +++ /dev/null @@ -1,6 +0,0 @@ -# yaml-language-server: $schema=https://raw.githubusercontent.com/trueforge-org/forgetool/refs/heads/main/pkg/containers/test/container-test.schema.json - -timeoutSeconds: 240 -http: -- port: '3214' - path: /