"check_instance",
help="Checks given instance if it exists and returns proper exit code"
)
- parser.add_argument("--domain", required=True, help="Instance name (aka. domain) to check")
parser.set_defaults(command=commands.check_instance)
+ parser.add_argument("--domain", required=True, help="Instance name (aka. domain) to check")
### Fetch from bka.li ###
parser = subparser_command.add_parser(
"recheck_obfuscation",
help="Checks all instance's obfuscated peers if they can be de-obfuscated now.",
)
+ parser.set_defaults(command=commands.recheck_obfuscation)
parser.add_argument("--domain", help="Instance name (aka. domain)")
parser.add_argument("--software", help="Name of software, e.g. 'lemmy'")
parser.add_argument("--force", action="store_true", help="Include also already existing instances, otherwise only new are checked")
- parser.set_defaults(command=commands.recheck_obfuscation)
### Fetch blocks from registered instances or given ###
parser = subparser_command.add_parser(
"fetch_fba_rss",
help="Fetches domains from a FBA-specific RSS feed.",
)
- parser.add_argument("--feed", required=True, help="RSS feed to fetch domains from (e.g. https://fba.ryoma.agency/rss?domain=foo.bar).")
parser.set_defaults(command=commands.fetch_fba_rss)
+ parser.add_argument("--feed", required=True, help="RSS feed to fetch domains from (e.g. https://fba.ryoma.agency/rss?domain=foo.bar).")
### Fetch blocks from FBA's bot account ###
parser = subparser_command.add_parser(
help="Fetches ATOM feed with domains from FBA's bot account.",
)
parser.set_defaults(command=commands.fetch_fbabot_atom)
+ parser.add_argument("--feed", required=True, help="RSS feed to fetch domains from (e.g. https://fba.ryoma.agency/rss?domain=foo.bar).")
### Fetch blocks from oliphant's GIT repository ###
parser = subparser_command.add_parser(
"fetch_oliphant",
help="Fetches CSV files (block recommendations) for more possible instances to disover",
)
- parser.add_argument("--domain", help="Instance name (aka. domain) to check")
parser.set_defaults(command=commands.fetch_oliphant)
+ parser.add_argument("--domain", help="Instance name (aka. domain) to check")
### Fetch instances from given initial instance ###
parser = subparser_command.add_parser(
"fetch_instances",
help="Fetches instances (aka. \"domains\") from an initial instance. You may want to re-run this command several times (at least 3 with big instances) to have a decent amount of valid instances.",
)
+ parser.set_defaults(command=commands.fetch_instances)
parser.add_argument("--domain", required=True, help="Instance name (aka. domain) to fetch further instances from. Start with a large instance, e.g. mastodon.social .")
parser.add_argument("--single", action="store_true", help="Only fetch given instance.")
- parser.set_defaults(command=commands.fetch_instances)
### Fetch blocks from static text file(s) ###
parser = subparser_command.add_parser(
locking.acquire()
source_domain = "ryona.agency"
+ feed = f"https://{source_domain}/users/fba/feed.atom"
+
+ logger.debug("args.feed[%s]='%s'", type(args.feed), args.feed)
+ if args.feed is not None and validators.url(args.feed):
+ logger.debug("Setting feed='%s' ...", args.feed)
+ feed = str(args.feed)
+ source_domain = urlparse(args.feed).netloc
+
if sources.is_recent(source_domain):
logger.info("API from source_domain='%s' has recently being accessed - EXIT!", source_domain)
return 0
logger.debug("source_domain='%s' has not been recently used, marking ...", source_domain)
sources.update(source_domain)
- feed = f"https://{source_domain}/users/fba/feed.atom"
-
domains = list()
logger.info("Fetching ATOM feed='%s' from FBA bot account ...", feed)