mastodon_ynh/scripts/_common.sh

50 lines
1.7 KiB
Bash
Raw Normal View History

2017-04-08 02:04:27 +00:00
#!/bin/bash
2019-03-18 03:22:38 +00:00
#=================================================
# COMMON VARIABLES
#=================================================
2022-09-19 23:57:06 +00:00
# dependencies used by the app (must be on a single line)
2022-01-04 14:32:36 +00:00
pkg_dependencies="imagemagick ffmpeg libpq-dev libxml2-dev libxslt1-dev file git-core g++ libprotobuf-dev protobuf-compiler pkg-config gcc autoconf bison build-essential libssl-dev libyaml-dev libreadline6-dev zlib1g-dev libncurses5-dev libffi-dev libgdbm3|libgdbm6 libgdbm-dev redis-tools redis-server postgresql postgresql-contrib libidn11-dev libicu-dev libjemalloc-dev curl apt-transport-https"
2022-05-29 13:54:35 +00:00
build_pkg_dependencies=""
2019-03-18 03:22:38 +00:00
2022-05-29 13:54:35 +00:00
memory_needed="2560"
2023-04-04 18:10:16 +00:00
ruby_version=3.0.6
2022-09-19 23:57:06 +00:00
nodejs_version=16
2020-08-09 08:39:43 +00:00
# Workaround for Mastodon on Bullseye
# See https://github.com/mastodon/mastodon/issues/15751#issuecomment-873594463
if [ "$(lsb_release --codename --short)" = "bullseye" ]; then
2022-09-19 23:57:06 +00:00
case $YNH_ARCH in
amd64)
ld_preload="LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libjemalloc.so"
;;
arm64)
ld_preload="LD_PRELOAD=/usr/lib/aarch64-linux-gnu/libjemalloc.so"
;;
armhf)
ld_preload="LD_PRELOAD=/usr/lib/arm-linux-gnueabihf/libjemalloc.so"
;;
armel)
ld_preload="LD_PRELOAD=/usr/lib/arm-linux-gnueabi/libjemalloc.so"
;;
i386)
ld_preload="LD_PRELOAD=/usr/lib/i386-linux-gnu/libjemalloc.so"
;;
esac
else
2022-09-19 23:57:06 +00:00
ld_preload=""
fi
2019-03-18 03:22:38 +00:00
#=================================================
# PERSONAL HELPERS
#=================================================
#=================================================
# EXPERIMENTAL HELPERS
#=================================================
#=================================================
# FUTURE OFFICIAL HELPERS
#=================================================