Minimales Testprojekt um zu pruefen ob Hostinger Node.js funktioniert.
-
Erstellen Sie ein neues GitHub Repository (z.B.
hostinger-test) -
Pushen Sie diesen Ordner dorthin:
cd hostinger-test git init git add . git commit -m "Initial commit" git remote add origin https://github.com/IHR_USERNAME/hostinger-test.git git push -u origin main
-
In Hostinger:
- Websites → Website hinzufuegen → Node.js App
- GitHub Repository verbinden
- Framework: Express
- Deployen
-
Nach dem Deploy:
- Oeffnen Sie die temporaere Domain
- Sie sollten "Express Server funktioniert!" sehen
- Test-API:
/api/testzeigt JSON-Response
npm install
npm start
# Oeffnen Sie http://localhost:3000