mirror of
https://github.com/YunoHost-Apps/libreddit_ynh.git
synced 2024-09-03 19:36:05 +02:00
fix
This commit is contained in:
parent
1c2c03009f
commit
7ee90937c9
4 changed files with 60 additions and 8 deletions
52
conf/.env
Normal file
52
conf/.env
Normal file
|
@ -0,0 +1,52 @@
|
||||||
|
# Redlib configuration
|
||||||
|
# See the Configuration section of the README for a more detailed explanation of these settings.
|
||||||
|
|
||||||
|
# Instance-specific settings
|
||||||
|
# Enable SFW-only mode for the instance
|
||||||
|
REDLIB_SFW_ONLY=off
|
||||||
|
# Set a banner message for the instance
|
||||||
|
REDLIB_BANNER=
|
||||||
|
# Disable search engine indexing
|
||||||
|
REDLIB_ROBOTS_DISABLE_INDEXING=off
|
||||||
|
# Set the Pushshift frontend for "removed" links
|
||||||
|
REDLIB_PUSHSHIFT_FRONTEND=undelete.pullpush.io
|
||||||
|
|
||||||
|
# Default user settings
|
||||||
|
# Set the default theme (options: system, light, dark, black, dracula, nord, laserwave, violet, gold, rosebox, gruvboxdark, gruvboxlight)
|
||||||
|
REDLIB_DEFAULT_THEME=system
|
||||||
|
# Set the default front page (options: default, popular, all)
|
||||||
|
REDLIB_DEFAULT_FRONT_PAGE=default
|
||||||
|
# Set the default layout (options: card, clean, compact)
|
||||||
|
REDLIB_DEFAULT_LAYOUT=card
|
||||||
|
# Enable wide mode by default
|
||||||
|
REDLIB_DEFAULT_WIDE=off
|
||||||
|
# Set the default post sort method (options: hot, new, top, rising, controversial)
|
||||||
|
REDLIB_DEFAULT_POST_SORT=hot
|
||||||
|
# Set the default comment sort method (options: confidence, top, new, controversial, old)
|
||||||
|
REDLIB_DEFAULT_COMMENT_SORT=confidence
|
||||||
|
# Enable blurring Spoiler content by default
|
||||||
|
REDLIB_DEFAULT_BLUR_SPOILER=off
|
||||||
|
# Enable showing NSFW content by default
|
||||||
|
REDLIB_DEFAULT_SHOW_NSFW=off
|
||||||
|
# Enable blurring NSFW content by default
|
||||||
|
REDLIB_DEFAULT_BLUR_NSFW=off
|
||||||
|
# Enable HLS video format by default
|
||||||
|
REDLIB_DEFAULT_USE_HLS=off
|
||||||
|
# Hide HLS notification by default
|
||||||
|
REDLIB_DEFAULT_HIDE_HLS_NOTIFICATION=off
|
||||||
|
# Disable autoplay videos by default
|
||||||
|
REDLIB_DEFAULT_AUTOPLAY_VIDEOS=off
|
||||||
|
# Define a default list of subreddit subscriptions (format: sub1+sub2+sub3)
|
||||||
|
REDLIB_DEFAULT_SUBSCRIPTIONS=
|
||||||
|
# Define a default list of subreddit filters (format: sub1+sub2+sub3)
|
||||||
|
REDLIB_DEFAULT_FILTERS=
|
||||||
|
# Hide awards by default
|
||||||
|
REDLIB_DEFAULT_HIDE_AWARDS=off
|
||||||
|
# Hide sidebar and summary
|
||||||
|
REDLIB_DEFAULT_HIDE_SIDEBAR_AND_SUMMARY=off
|
||||||
|
# Disable the confirmation before visiting Reddit
|
||||||
|
REDLIB_DEFAULT_DISABLE_VISIT_REDDIT_CONFIRMATION=off
|
||||||
|
# Hide score by default
|
||||||
|
REDLIB_DEFAULT_HIDE_SCORE=off
|
||||||
|
# Enable fixed navbar by default
|
||||||
|
REDLIB_DEFAULT_FIXED_NAVBAR=on
|
|
@ -7,7 +7,7 @@ After=network.service
|
||||||
User=__APP__
|
User=__APP__
|
||||||
Group=__APP__
|
Group=__APP__
|
||||||
DynamicUser=yes
|
DynamicUser=yes
|
||||||
EnvironmentFile=-__INSTALL_DIR__/libreddit.conf
|
EnvironmentFile=-__INSTALL_DIR__/.env
|
||||||
ExecStart=__INSTALL_DIR__/libreddit -a 127.0.0.1 -p __PORT__
|
ExecStart=__INSTALL_DIR__/libreddit -a 127.0.0.1 -p __PORT__
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
|
|
|
@ -38,10 +38,10 @@ yunohost service add $app --description="Alternative to Reddit" --log="/var/log/
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Adding a configuration file..." --weight=1
|
ynh_script_progression --message="Adding a configuration file..." --weight=1
|
||||||
|
|
||||||
ynh_add_config --template="libreddit.conf" --destination="$install_dir/libreddit.conf"
|
ynh_add_config --template=".env" --destination="$install_dir/.env"
|
||||||
|
|
||||||
chmod 400 "$install_dir/libreddit.conf"
|
chmod 400 "$install_dir/.env"
|
||||||
chown $app:$app "$install_dir/libreddit.conf"
|
chown $app:$app "$install_dir/.env"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# START SYSTEMD SERVICE
|
# START SYSTEMD SERVICE
|
||||||
|
|
|
@ -30,7 +30,7 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path="systemd"
|
||||||
ynh_script_progression --message="Upgrading source files..." --weight=5
|
ynh_script_progression --message="Upgrading source files..." --weight=5
|
||||||
|
|
||||||
# Download, check integrity, uncompress and patch the source from app.src
|
# Download, check integrity, uncompress and patch the source from app.src
|
||||||
ynh_setup_source --dest_dir="$install_dir" --keep="libreddit.conf"
|
ynh_setup_source --dest_dir="$install_dir" --keep=".env"
|
||||||
|
|
||||||
chown -R $app:www-data "$install_dir"
|
chown -R $app:www-data "$install_dir"
|
||||||
chmod +x $install_dir/libreddit
|
chmod +x $install_dir/libreddit
|
||||||
|
@ -53,10 +53,10 @@ yunohost service add $app --description="Alternative to Reddit" --log="/var/log/
|
||||||
#=================================================
|
#=================================================
|
||||||
#ynh_script_progression --message="Updating a configuration file..." --weight=1
|
#ynh_script_progression --message="Updating a configuration file..." --weight=1
|
||||||
|
|
||||||
# ynh_add_config --template="libreddit.conf" --destination="$install_dir/libreddit.conf"
|
# ynh_add_config --template=".env" --destination="$install_dir/.env"
|
||||||
|
|
||||||
# chmod 400 "$install_dir/libreddit.conf"
|
# chmod 400 "$install_dir/.env"
|
||||||
# chown $app:$app "$install_dir/libreddit.conf"
|
# chown $app:$app "$install_dir/.env"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# START SYSTEMD SERVICE
|
# START SYSTEMD SERVICE
|
||||||
|
|
Loading…
Add table
Reference in a new issue