CanastaWiki / Canasta

MediaWiki Docker image for Canasta, an all-in-one MediaWiki stack for easy deployment and management of enterprise-ready MediaWiki on production environments.
https://www.canasta.wiki
MIT License
38 stars 28 forks source link

API for accessing MediaWiki info set in LocalSettings.php, etc? #114

Closed jeffw16 closed 2 years ago

jeffw16 commented 2 years ago

Canasta currently has no way to access the info stored in LocalSettings.php, so it can't, for instance, detect the database name. Can we make an API for doing this?

yaronkoren commented 2 years ago

I agree that this would be useful, but, rather than API action(s), I think this would be best implemented as a command-line script inserted within MediaWiki - it seems like it would be more secure, so that regular users couldn't access this information. But maybe by "API" you didn't necessarily mean the literal MW API.

jeffw16 commented 2 years ago

But maybe by "API" you didn't necessarily mean the literal MW API.

Correct, I should've been more clear that this should not be a web API.

I think this would be best implemented as a command-line script inserted within MediaWiki

I completely agree!

it seems like it would be more secure, so that regular users couldn't access this information

Completely agreed; in fact, I see no reason why a regular user should be using this proposed API.

yaronkoren commented 2 years ago

This is done now.