A partial archive of https://discourse-mediawiki.wmflabs.org as of Saturday May 21, 2022.

Include mobileapps services into RESTbase locally

WMDE-Fisch

Hej folks,

for my local ( “custom” nginx,mysql ) MediaWiki I want to have the RESTbase running with Parsoid and mobileapps services included. I set up my RESTbase and Parsoid following the instructions [1] [2] and they work fine together.

Now I setup the mobileapps services and tried to include them by roughly following [3] with the main difference, that I did not copy the config.example.wikimedia.yaml but just changed the mobileapps path in the minimal example.yaml used from before.

Now I have a working stand alone mobile apps service but it’s not included into the RESTbase and I have no idea what I’m missing. :-/

RESTbase config: https://tools.wmflabs.org/paste/view/d87efb24
MobileApps services: https://tools.wmflabs.org/paste/view/5605020d

[1] https://www.mediawiki.org/wiki/Parsoid/Setup
[2] https://www.mediawiki.org/wiki/Parsoid/Setup/RESTBase#Pointing_RESTBase_at_a_local_Parsoid
[3] https://www.mediawiki.org/wiki/Wikimedia_Apps/Team/RESTBase_services_for_apps#Setting_up_a_local_RESTBase_instance

Tgr

I think the RESTBase example config is inconsistent there, there is a mobileapps key under options but mobileapps are actually not included in project/example.yaml which is the definition. The non-example files include mobileapps with the - path: v1/summary.js line I believe.

ppchelko

In case you just need the summary, @Tgr answer is enough. In case you need to enable MCS endpioints as well, you’d need to copy https://github.com/wikimedia/restbase/blob/master/projects/wmf_enwiki.yaml#L68 and https://github.com/wikimedia/restbase/blob/master/projects/wmf_enwiki.yaml#L219-L236
to projects/example.yaml

WMDE-Fisch

Ahhh! The project/example.yaml was the missing piece :-). - In may case the route(?) for the reference endpoint is the one missing. So the answer here is https://github.com/wikimedia/restbase/blob/master/projects/wmf_enwiki.yaml#L84,L87

Works like a charm now. thanks again!