my_webapp_ynh
my_webapp_ynh copied to clipboard
Add NodeJS server as an alternative to PHP
Problem
I wanted to have an app similar to my_webapp but with nodejs instead of PHP. After hesitating to create a new app, I decided it was better to improve this one instead.
Solution
For this, I added, with the help of @oiseauroch:
- Two entries in the manifest:
- A choice for the NodeJS version
- A port (provisionned in any case due to ynh limitations, but this should not matter)
- Services and configs:
- Systemctl configs to run the NodeJS server
- A watcher service and path to restart NodeJS upon file update
- A custom NGinx config because it is incompatible with the default one
- Docs:
- More info in the description and admin
The install/remove/backup/restore have been adapted and tested. The upgrade script is updated but not tested The change_url script does not change
It is not possible to have both PHP and NodeJS to keep the scripts simple.
PR Status
- [x] Code finished and ready to be reviewed/tested
- [x] The fix/enhancement were manually tested (if applicable)
Automatic tests
Automatic tests can be triggered on https://ci-apps-dev.yunohost.org/ after creating the PR, by commenting "!testme", "!gogogadgetoci" or "By the power of systemd, I invoke The Great App CI to test this Pull Request!". (N.B. : for this to work you need to be a member of the Yunohost-Apps organization)