First Run
What Happens on First Run
When ZyveraWeb starts for the first time with an empty plugins/ZyveraWeb/ directory, it automatically populates the following files:
Default Configuration
config.yml is created with sensible defaults:
host: "0.0.0.0"
port: 8080
api:
cors-origins:
rate-limit:
placeholder:
requests: 180
per: 30s
players:
requests: 200
per: 20s
sites:
- domain: ""
dir: "site/default"
Default Static Website
The default website (site/default/) displays a welcome message and live player list:
index.html— HTML page with a player grid containerstyle.css— Styling for the player gridscript.js— JavaScript that fetches/api/playersand displays online players
Example Node.js Projects
Two demonstration projects are created in site/:
site/demo/ — Simple API Backend
server.js— Handles/api/info,/api/echo, and/api/messageroutespublic/— Vanilla JS frontend that calls the APIpackage.json— Empty (no npm dependencies)
site/react-demo/ — React SPA + API Backend
server.js— API endpoint returning JSONpublic/— React SPA (React loaded from CDN)package.json— Empty (uses CDN React)
What You Should Do After First Run
- Review
config.yml— Adjust the port and rate limits for your environment. - Customize the website — Replace files in
site/default/with your own content. - Configure a domain — If you have a domain, add it to a site entry in the
sites:section and point your DNS to the server IP. - Enable SSL — Either set up automatic certificates with the
/zyveraweb acmecommand or place your own certificates in thessl/folder and add anssl:block to your site. - Set up virtual hosts — Add multiple sites under the
sites:section in config.yml (see Virtual Hosts).
Persistent State
The following are persisted across restarts:
config.yml— Not overwritten after initial creationsite/files — Not overwritten after initial creationssl/certificates — Persist until replacednode_modules/directories — npm packages are preserved
No comments to display
No comments to display