@@ -79,6 +79,8 @@ const generateEditorEnv = (config, deploymentType) => {
7979 if ( deploymentType !== 'aio' ) {
8080 if ( redisExternal ) {
8181 // External Redis - editor connects to m3u-redis container
82+ // Disable embedded Redis since we're using external
83+ addEnvVar ( envVars , 'REDIS_ENABLED' , false ) ;
8284 addEnvVar ( envVars , 'REDIS_HOST' , 'm3u-redis' ) ;
8385 addEnvVar ( envVars , 'REDIS_SERVER_PORT' , config . REDIS_SERVER_PORT || '6379' ) ;
8486 addEnvVar ( envVars , 'REDIS_PASSWORD' , config . REDIS_PASSWORD ) ;
@@ -138,9 +140,9 @@ const generateVolumes = (config) => {
138140// Generate m3u-proxy service
139141const generateProxyService = ( config , useVpnNetwork = false ) => {
140142 const redisExternal = isRedisExternal ( config ) ;
141- const redisAddr = redisExternal
142- ? ` m3u-redis: ${ config . REDIS_SERVER_PORT || '6379' } `
143- : ` m3u-editor: ${ config . REDIS_SERVER_PORT || '6379' } ` ;
143+ // When redis is external, proxy connects to m3u-redis container
144+ // When redis is internal (embedded in editor), proxy connects to m3u-editor container
145+ const redisHost = redisExternal ? ' m3u-redis' : 'm3u-editor' ;
144146
145147 let service = `
146148 m3u-proxy:
@@ -155,13 +157,22 @@ const generateProxyService = (config, useVpnNetwork = false) => {
155157 service += `
156158 environment:
157159 - API_TOKEN=\${M3U_PROXY_TOKEN:-${ config . M3U_PROXY_TOKEN } }
158- - REDIS_ADDR=${ redisAddr } ` ;
160+ - REDIS_ENABLED=true
161+ - REDIS_HOST=${ redisHost }
162+ - REDIS_SERVER_PORT=${ config . REDIS_SERVER_PORT || '6379' }
163+ - REDIS_DB=6` ;
159164
160165 if ( redisExternal && config . REDIS_PASSWORD ) {
161166 service += `
162167 - REDIS_PASSWORD=\${REDIS_PASSWORD:-${ config . REDIS_PASSWORD } }` ;
163168 }
164169
170+ // Only add ENABLE_TRANSCODING_POOLING if it's enabled (default true)
171+ if ( config . ENABLE_TRANSCODING_POOLING !== false ) {
172+ service += `
173+ - ENABLE_TRANSCODING_POOLING=true` ;
174+ }
175+
165176 service += `
166177 - LOG_LEVEL=${ config . M3U_PROXY_LOG_LEVEL || 'INFO' } ` ;
167178
@@ -181,6 +192,9 @@ const generateProxyService = (config, useVpnNetwork = false) => {
181192 if ( redisExternal ) {
182193 service += `
183194 - m3u-redis` ;
195+ } else {
196+ service += `
197+ - m3u-editor` ;
184198 }
185199 } else {
186200 if ( redisExternal ) {
0 commit comments