From 4eedc672a1fa2defc32db8ab635a2904a78b8b82 Mon Sep 17 00:00:00 2001 From: Cassowary Date: Mon, 9 Oct 2023 09:31:27 -0700 Subject: [PATCH] Multiple fixes --- .env.sample | 2 +- README.md | 6 +----- abra.sh | 2 +- compose.yml | 8 ++++---- entrypoint.sh.tmpl | 9 ++++++--- 5 files changed, 13 insertions(+), 14 deletions(-) diff --git a/.env.sample b/.env.sample index 3a69807..f036dbc 100644 --- a/.env.sample +++ b/.env.sample @@ -35,7 +35,7 @@ LIMITED_FEDERATION_MODE=false # Deployment # ---------- RAILS_ENV=production -RAILS_SERVE_STATIC_FILES=true # might need this for traefik, need to test +RAILS_SERVE_STATIC_FILES=true # TRUSTED_PROXY_IP= # External Services diff --git a/README.md b/README.md index 0dd2437..f82fa02 100644 --- a/README.md +++ b/README.md @@ -24,12 +24,8 @@ discussed. See the [`coop-cloud/mastodon` `README.md`](https://git.coopcloud.tech/coop-cloud/mastodon#quick-start). -Watch out in case the Mastodon recipe latest is not the same as the Hometown -latest version! You can switch back to a compatible tag on the Mastodon recipe -to compare docs, config etc. just to be sure. - ## Tips & Tricks See the [`coop-cloud/mastodon` `README.md`](https://git.coopcloud.tech/coop-cloud/mastodon#admin-tips-tricks). -Please only gather tips & tricks that are specific to Hometown here. +Please only gather tips & tricks that are specific to Glitch-soc here. diff --git a/abra.sh b/abra.sh index aa3b18d..176eff8 100755 --- a/abra.sh +++ b/abra.sh @@ -1,6 +1,6 @@ #!/bin/bash -export ENTRYPOINT_CONF_VERSION=v11 +export ENTRYPOINT_CONF_VERSION=v12 # assets() { # set -x OTP_SECRET $(cat /run/secrets/otp_secret) diff --git a/compose.yml b/compose.yml index 107a0be..05cac9a 100644 --- a/compose.yml +++ b/compose.yml @@ -3,8 +3,8 @@ version: "3.8" services: app: - image: lscr.io/linuxserver/mastodon:glitch-ebd20175-ls78 - # command: bash -c "rm -f /mastodon/tmp/pids/server.pid; bundle exec rails s -p 3000" + image: yakumosaki/glitch-soc:20230927_13 + command: bash -c "rm -f /mastodon/tmp/pids/server.pid; bundle exec rails s -p 3000" networks: &bothNetworks - proxy - internal_network @@ -24,8 +24,8 @@ services: - source: entrypoint_sh target: /usr/local/bin/entrypoint.sh mode: 0555 - # entrypoint: &entrypoint /usr/local/bin/entrypoint.sh - entrypoint: &entrypoint ['tail', '-f', '/dev/null'] + entrypoint: &entrypoint /usr/local/bin/entrypoint.sh + # entrypoint: &entrypoint ['tail', '-f', '/dev/null'] volumes: &appVolume - app:/opt/mastodon/public/system #healthcheck: diff --git a/entrypoint.sh.tmpl b/entrypoint.sh.tmpl index 25e83f6..88eab5e 100755 --- a/entrypoint.sh.tmpl +++ b/entrypoint.sh.tmpl @@ -30,15 +30,18 @@ file_env "DB_PASS" file_env "SMTP_PASSWORD" file_env "VAPID_PRIVATE_KEY" +export RAILS_ENV=production + {{ if eq (env "OIDC_ENABLED") "true" }} file_env "OIDC_CLIENT_SECRET" {{ end }} -export RAILS_ENV=production + bundle exec rake db:setup || /bin/true -#bundle exec rake webpacker:verify_install || bundle exec rake webpacker:install +# bundle exec rake webpacker:verify_install || bundle exec rake webpacker:install #bundle exec rake webpacker:yarn_install -bundle exec rake assets:precompile || /bin/true +# bundle exec rake assets:clobber +# bundle exec rake assets:precompile || /bin/true /usr/bin/tini -s -- "$@"