Update remaining alternative frontends to use Farside

Wikipedia, imgur, and translate alternatives were all still using
hardcoded URLs when replaced with their respective alternative frontend.
This updates them to use farside instead.
main
Ben Busby 2022-03-21 10:08:52 -06:00
parent a58f70ca7e
commit 0048c2f9aa
No known key found for this signature in database
GPG Key ID: B9B7231E01D924A1
8 changed files with 19 additions and 19 deletions

View File

@ -40,9 +40,9 @@ ARG youtube_alt='farside.link/invidious'
ARG instagram_alt='farside.link/bibliogram' ARG instagram_alt='farside.link/bibliogram'
ARG reddit_alt='farside.link/libreddit' ARG reddit_alt='farside.link/libreddit'
ARG medium_alt='farside.link/scribe' ARG medium_alt='farside.link/scribe'
ARG translate_alt='lingva.ml' ARG translate_alt='farside.link/lingva'
ARG imgur_alt='imgin.voidnet.tech' ARG imgur_alt='farside.link/rimgo'
ARG wikipedia_alt='wikiless.org' ARG wikipedia_alt='farside.link/wikiless'
ENV CONFIG_VOLUME=$config_dir \ ENV CONFIG_VOLUME=$config_dir \
WHOOGLE_USER=$username \ WHOOGLE_USER=$username \

View File

@ -202,9 +202,9 @@ Description=Whoogle
#Environment=WHOOGLE_ALT_IG=farside.link/bibliogram/u #Environment=WHOOGLE_ALT_IG=farside.link/bibliogram/u
#Environment=WHOOGLE_ALT_RD=farside.link/libreddit #Environment=WHOOGLE_ALT_RD=farside.link/libreddit
#Environment=WHOOGLE_ALT_MD=farside.link/scribe #Environment=WHOOGLE_ALT_MD=farside.link/scribe
#Environment=WHOOGLE_ALT_TL=lingva.ml #Environment=WHOOGLE_ALT_TL=farside.link/lingva
#Environment=WHOOGLE_ALT_IMG=imgin.voidnet.tech #Environment=WHOOGLE_ALT_IMG=farside.link/rimgo
#Environment=WHOOGLE_ALT_WIKI=wikiless.org #Environment=WHOOGLE_ALT_WIKI=farside.link/wikiless
# Load values from dotenv only # Load values from dotenv only
#Environment=WHOOGLE_DOTENV=1 #Environment=WHOOGLE_DOTENV=1
Type=simple Type=simple

View File

@ -72,17 +72,17 @@
}, },
"WHOOGLE_ALT_TL": { "WHOOGLE_ALT_TL": {
"description": "The Google Translate alternative to use for all searches following the 'translate ___' structure.", "description": "The Google Translate alternative to use for all searches following the 'translate ___' structure.",
"value": "lingva.ml", "value": "farside.link/lingva",
"required": false "required": false
}, },
"WHOOGLE_ALT_IMG": { "WHOOGLE_ALT_IMG": {
"description": "The site to use as a replacement for imgur.com when site alternatives are enabled in the config.", "description": "The site to use as a replacement for imgur.com when site alternatives are enabled in the config.",
"value": "imgin.voidnet.tech", "value": "farside.link/rimgo",
"required": false "required": false
}, },
"WHOOGLE_ALT_WIKI": { "WHOOGLE_ALT_WIKI": {
"description": "The site to use as a replacement for wikipedia.com when site alternatives are enabled in the config.", "description": "The site to use as a replacement for wikipedia.com when site alternatives are enabled in the config.",
"value": "wikiless.org", "value": "farside.link/wikiless",
"required": false "required": false
}, },
"WHOOGLE_MINIMAL": { "WHOOGLE_MINIMAL": {

View File

@ -82,7 +82,7 @@ app.config['HAS_UPDATE'] = ''
# The alternative to Google Translate is treated a bit differently than other # The alternative to Google Translate is treated a bit differently than other
# social media site alternatives, in that it is used for any translation # social media site alternatives, in that it is used for any translation
# related searches. # related searches.
translate_url = os.getenv('WHOOGLE_ALT_TL', 'https://lingva.ml') translate_url = os.getenv('WHOOGLE_ALT_TL', 'https://farside.link/lingva')
if not translate_url.startswith('http'): if not translate_url.startswith('http'):
translate_url = 'https://' + translate_url translate_url = 'https://' + translate_url
app.config['TRANSLATE_URL'] = translate_url app.config['TRANSLATE_URL'] = translate_url

View File

@ -34,8 +34,8 @@ SITE_ALTS = {
'medium.com', 'medium.com',
'levelup.gitconnected.com' 'levelup.gitconnected.com'
], os.getenv('WHOOGLE_ALT_MD', 'farside.link/scribe')), ], os.getenv('WHOOGLE_ALT_MD', 'farside.link/scribe')),
'imgur.com': os.getenv('WHOOGLE_ALT_IMG', 'imgin.voidnet.tech'), 'imgur.com': os.getenv('WHOOGLE_ALT_IMG', 'farside.link/rimgo'),
'wikipedia.org': os.getenv('WHOOGLE_ALT_WIKI', 'wikiless.org') 'wikipedia.org': os.getenv('WHOOGLE_ALT_WIKI', 'farside.link/wikiless')
} }

View File

@ -37,9 +37,9 @@ services:
#- WHOOGLE_ALT_IG=farside.link/bibliogram/u #- WHOOGLE_ALT_IG=farside.link/bibliogram/u
#- WHOOGLE_ALT_RD=farside.link/libreddit #- WHOOGLE_ALT_RD=farside.link/libreddit
#- WHOOGLE_ALT_MD=farside.link/scribe #- WHOOGLE_ALT_MD=farside.link/scribe
#- WHOOGLE_ALT_TL=lingva.ml #- WHOOGLE_ALT_TL=farside.link/lingva
#- WHOOGLE_ALT_IMG=imgin.voidnet.tech #- WHOOGLE_ALT_IMG=farside.link/rimgo
#- WHOOGLE_ALT_WIKI=wikiless.org #- WHOOGLE_ALT_WIKI=farside.link/wikiless
#env_file: # Alternatively, load variables from whoogle.env #env_file: # Alternatively, load variables from whoogle.env
#- whoogle.env #- whoogle.env
ports: ports:

View File

@ -60,7 +60,7 @@ def test_translate_search(client):
# Pretty weak test, but better than nothing # Pretty weak test, but better than nothing
str_data = str(rv.data) str_data = str(rv.data)
assert 'iframe' in str_data assert 'iframe' in str_data
assert 'lingva.ml/auto/en/ hola' in str_data assert '/auto/en/ hola' in str_data
def test_block_results(client): def test_block_results(client):

View File

@ -12,9 +12,9 @@
#WHOOGLE_ALT_IG=farside.link/bibliogram/u #WHOOGLE_ALT_IG=farside.link/bibliogram/u
#WHOOGLE_ALT_RD=farside.link/libreddit #WHOOGLE_ALT_RD=farside.link/libreddit
#WHOOGLE_ALT_MD=farside.link/scribe #WHOOGLE_ALT_MD=farside.link/scribe
#WHOOGLE_ALT_TL=lingva.ml #WHOOGLE_ALT_TL=farside.link/lingva
#WHOOGLE_ALT_IMG=imgin.voidnet.tech #WHOOGLE_ALT_IMG=farside.link/rimgo
#WHOOGLE_ALT_WIKI=wikiless.org #WHOOGLE_ALT_WIKI=farside.link/wikiless
#WHOOGLE_USER="" #WHOOGLE_USER=""
#WHOOGLE_PASS="" #WHOOGLE_PASS=""
#WHOOGLE_PROXY_USER="" #WHOOGLE_PROXY_USER=""