Deployment - cynchro/OldSchoolFrontFrame GitHub Wiki
OLS apps are static files — no server runtime, no build step, no compilation. Deploy anywhere that serves static files.
The repository includes a Dockerfile and docker-compose.yml using Nginx:
docker compose up --buildServes the app at http://localhost:9000/example/.
To customize the port, edit docker-compose.yml:
ports:
- "8080:80" # change 9000 → 8080Example nginx.conf (also included in the repo):
server {
listen 80;
server_name _;
root /usr/share/nginx/html;
index index.html;
location / {
try_files $uri $uri/ /index.html;
}
}The try_files directive ensures direct URL access works even with hash routing. Hash URLs don't reach the server, but it's a safe default.
<VirtualHost *:80>
DocumentRoot /var/www/myapp
DirectoryIndex index.html
<Directory /var/www/myapp>
AllowOverride All
Require all granted
</Directory>
</VirtualHost>No .htaccess rewrite rules are needed — hash routing is handled entirely in the browser.
- Push your app to a GitHub repository
- Go to Settings → Pages
- Set source to your branch and folder (e.g.
/rootor/docs) - Your app is live at
https://<user>.github.io/<repo>/
Update import paths if deploying to a subdirectory:
// app.js — if deployed to /myapp/
initApp({
routes: { home: 'home' },
config: { yamlPath: './myapp/config/app.yaml' },
});OLS apps work on:
- Netlify (drag & drop the folder)
- Vercel (static output)
- AWS S3 + CloudFront
- Azure Static Web Apps
- Cloudflare Pages
- PHP shared hosting (just copy files)
The only requirement is that files are served over HTTP or HTTPS (not file://), because ES modules require a proper origin for CORS.
- Set
dev: falseininitApp()(removes console logs andwindow.$ols) - Set correct
config.yamlPath/config.jsonPathfor production environment - Verify all module paths are correct relative to the served root
- Confirm the static server sets appropriate cache headers for JS/CSS assets
- Test navigation by directly opening hash URLs (e.g.
https://example.com/#/clientes)