Spaces:
Paused
Paused
Update config.js
Browse files123456789101112131415161718192021var env = process.env.NODE_ENV ? 'beamup':'local';var config = {addon: 'started',}switch (env) {//Public server build.case 'beamup':config.port = process.env.PORTconfig.local = "5a0d1888fa64-your-iptv.baby-beamup.club"break;//Local sever build.case 'local':config.port = 3649config.local = "http://127.0.0.1:" + config.port;break;}module.exports = config;1234567891011121314151617181920212223// Detect the environment, defaulting to 'local' if NODE_ENV is not setvar env = process.env.NODE_ENV === 'production' ? 'production' : 'local';// Initialize config with default valuesvar config = {addon: 'started',port: process.env.PORT || 3000 // Use PORT from environment or default to 3000};// Environment-specific configurationswitch (env) {// Hugging Face server build (production)case 'production':config.local = `http://0.0.0.0:${config.port}`; // Required binding for Hugging Face deploymentbreak;// Local server build (development)case 'local':config.local = `http://127.0.0.1:${config.port}`; // Localhost URL with portbreak;}module.exports = config;
config.js+23-21