bpking1 / embyExternalUrl

some emby/jellyfin scripts
MIT License
695 stars 124 forks source link

nginx-emby启动失败 #235

Closed l648741695 closed 3 months ago

l648741695 commented 3 months ago
根据docker-compose安装,nginx容器启动失败,日志如下,请大佬帮忙看看,谢谢~ 2024/06/21 14:47:57 stderr nginx: [emerg] unknown directive "js_shared_dict_zone" in /etc/nginx/conf.d/emby.conf:11
2024/06/21 14:47:57 stdout /docker-entrypoint.sh: Configuration complete; ready for start up
2024/06/21 14:47:57 stdout /docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh
2024/06/21 14:47:57 stdout /docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh
2024/06/21 14:47:57 stdout 10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist
2024/06/21 14:47:57 stdout /docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh
2024/06/21 14:47:57 stdout /docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
2024/06/21 14:47:57 stdout /docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
chen3861229 commented 3 months ago

unknown directive "js_shared_dict_zone"

用的 nginx 内置的 NJS 版本稍微有些低了,js_shared_dict_zone 这个在脚本中当作内存缓存用了,建议 image: nginx:latest 并确保 NJS 版本 >= 0.8.0,版本号可在容器终端中输入 njs 或 njs -v 进行查看

https://nginx.org/en/docs/http/ngx_http_js_module.html#js_shared_dict_zone