配置Apache和Renderd时插座绑定失败
我正在尝试通过在 switch2OSM 。
我不是在教程中所述使用Ubuntu,而是使用Docker用于所有内容(Postgis,Apache等),
我正在尝试构建配置Apache和Renderd的映像(我遵循找到的说明在这里)
这是我的dockerfile:
FROM httpd:2.4
RUN apt-get update && \
apt-get install -y libapache2-mod-tile renderd
RUN a2enmod tile
RUN a2enconf renderd
CMD ["renderd", "-f", "&&", "httpd-foreground"]
我在构建和创建容器后一直遇到此错误:
renderd[1]: Initialising unix server socket on /run/renderd/renderd.sock
socket bind failed for: /run/renderd/renderd.sock
我知道这是一个用户正确的问题,但我看不到如何修复它。
请谁能帮助我解决这个问题?
I am trying to build a custom map server tile server by following this tutorial on switch2osm.
Instead of using ubuntu as described in the tutorial, I am using docker for everything (postgis, apache, etc)
I am trying to build an image where apache and renderd are configured (I followed the instructions found here)
Here is my Dockerfile :
FROM httpd:2.4
RUN apt-get update && \
apt-get install -y libapache2-mod-tile renderd
RUN a2enmod tile
RUN a2enconf renderd
CMD ["renderd", "-f", "&&", "httpd-foreground"]
I keep having this error after building and creating the container :
renderd[1]: Initialising unix server socket on /run/renderd/renderd.sock
socket bind failed for: /run/renderd/renderd.sock
I know that's a user right issue but I dont see how to fix it.
Please can anyone help me solves this issue ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
更多
发布评论
评论(2)
我看到了同样的问题。我已经通过Sudo Chown -R OSM更改 /Run /Renderd的所有者进行了部分解决,
然后重新启动渲染过程。
我已经进一步尝试(并且失败)通过修改文件来永久性:
/etc/systemd/system/multi-user.target.wants/renderd.service
并在此指定用户以及
[service] execstart =/usr/bin/renderd -f user = osm
我确实相信上述'fix''现在在Ubuntu 22.04
上工作Roger Hellman的答案:
在Ubuntu上永久性22.04更改所有者_renderd of/run/renderd of/run/underde .conf。
I saw the same problem. I've partially resolved it by changing the owner of /run/renderd via sudo chown -R osm:osm /run/renderd
Then restarting the renderd process.
I've further tried (and failed) to make this permanent by modifying the file:
/etc/systemd/system/multi-user.target.wants/renderd.service
and specify the user there as well
[Service] ExecStart=/usr/bin/renderd -f User=osm
I do believe the above 'fix' has worked in the past, but doesn't seem to work now on Ubuntu 22.04
An addition to Roger Hellman's answer:
To make this permanent on Ubuntu 22.04 change the owner _renderd of /run/renderd to osm in the file /usr/lib/tmpfiles.d/renderd.conf.
这对我有用
This worked for me