Compare commits

...

7 commits

Author SHA1 Message Date
pch_xyz 8d5b097ac4 Add donation link 2023-02-26 05:27:32 +00:00
pch_xyz 8c49d92aea added version info 2023-02-10 01:15:20 +00:00
pch_xyz d06f51fca6 上傳檔案到「relay」
added version info
2023-02-10 01:14:32 +00:00
pch_xyz 818a3573ae Merge pull request 'localization' (#1) from pch_xyz-patch-1 into master
Reviewed-on: #1
2023-02-10 00:54:07 +00:00
pch_xyz 3dea5c030b localization 2023-02-10 00:51:40 +00:00
Izalia Mae 15b1324df2 Merge branch 'zen-master-patch-50595' into 'master'
Do not check instance's actor.type in case of Pleroma/Akkoma

See merge request pleroma/relay!50
2023-01-11 03:43:59 +00:00
Dmytro Poltavchenko 006efc1ba4 Do not check instance's actor.type in case of Pleroma/Akkoma 2023-01-08 00:23:36 +00:00
2 changed files with 11 additions and 8 deletions

View file

@ -11,12 +11,12 @@ cache = LRUCache(1024)
def person_check(actor, software):
## pleroma and akkoma use Person for the actor type for some reason
if software in {'akkoma', 'pleroma'} and actor.id != f'https://{actor.domain}/relay':
return True
## pleroma and akkoma may use Person for the actor type for some reason
if software in {'akkoma', 'pleroma'} and actor.id == f'https://{actor.domain}/relay':
return False
## make sure the actor is an application
elif actor.type != 'Application':
if actor.type != 'Application':
return True

View file

@ -41,7 +41,7 @@ async def home(request):
text = f"""
<html><head>
<title>ActivityPub Relay at {host}</title>
<title>SEDI中繼器</title>
<style>
p {{ color: #FFFFFF; font-family: monospace, arial; font-size: 100%; }}
body {{ background-color: #000000; }}
@ -53,9 +53,12 @@ a:hover {{ color: #8AF; }}
<body>
<p>This is an Activity Relay for fediverse instances.</p>
<p>{note}</p>
<p>You may subscribe to this relay with the address: <a href="https://{host}/actor">https://{host}/actor</a></p>
<p>To host your own relay, you may download the code at this address: <a href="https://git.pleroma.social/pleroma/relay">https://git.pleroma.social/pleroma/relay</a></p>
<br><p>List of {count} registered instances:<br>{targets}</p>
<p>Misskey及Mastodon站長請訂閱這個地址<a href="https://{host}/inbox">https://{host}/inbox</a></p>
<p>Pleroma及Friendica站長請訂閱這個地址<a href="https://{host}/actor">https://{host}/actor</a></p>
<p>原始碼<a href="https://git.seediqbale.xyz/pch_xyz/sedi-relay">https://git.seediqbale.xyz/pch_xyz/sedi-relay</a></p>
<p>請我喝杯咖啡<a href="https://buymeacoffee.com/SEDI">https://buymeacoffee.com/SEDI</a></p>
<p>activityrelay v0.2.4</p>
<br><p> {count} 個實例訂閱中<br>{targets}</p>
</body></html>"""
return Response.new(text, ctype='html')