首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Pihole部署使用helm重新启动

Pihole部署使用helm重新启动
EN

Stack Overflow用户
提问于 2020-10-01 06:08:01
回答 1查看 430关注 0票数 0

我正在尝试通过helm在Docker上的Kubernetes集群上安装pihole。我正在跟随this guide这样做。一切似乎都很顺利。我得到了一个补全:

代码语言:javascript
复制
NAME: pihole
LAST DEPLOYED: Wed Sep 30 22:22:15 2020
NAMESPACE: pihole
STATUS: deployed
REVISION: 1
TEST SUITE: None

但是pihole永远不会达到就绪状态,它只是在几分钟后重新启动。在检查pod时,我看到:

代码语言:javascript
复制
lastState:
    terminated:
        containerID: docker://16e2a318b460d4d5aebd502175fb688fc150993940181827a506c086e2cb326a
        exitCode: 0
        finishedAt: "2020-09-30T22:01:55Z"
        reason: Completed
        startedAt: "2020-09-30T21:59:17Z"

如何防止它在完成后不断地重新启动?

以下是kubectl logs 的输出:

代码语言:javascript
复制
[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] 01-resolver-resolv: applying...
[fix-attrs.d] 01-resolver-resolv: exited 0.
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] 20-start.sh: executing...
 ::: Starting docker specific checks & setup for docker pihole/pihole
  [✓] Update local cache of available packages
  [i] Existing PHP installation detected : PHP version 7.0.33-0+deb9u8

  [i] Installing configs from /etc/.pihole...
  [i] Existing dnsmasq.conf found... it is not a Pi-hole file, leaving alone!
  [✓] Copying 01-pihole.conf to /etc/dnsmasq.d/01-pihole.conf
chown: cannot access '': No such file or directory
chmod: cannot access '': No such file or directory
chown: cannot access '/etc/pihole/dhcp.leases': No such file or directory
::: Pre existing WEBPASSWORD found
Using default DNS servers: 8.8.8.8 & 8.8.4.4
DNSMasq binding to default interface: eth0
Added ENV to php:
                        "PHP_ERROR_LOG" => "/var/log/lighttpd/error.log",
                        "ServerIP" => "0.0.0.0",
                        "VIRTUAL_HOST" => "pi.hole",
Using IPv4 and IPv6
::: Preexisting ad list /etc/pihole/adlists.list detected ((exiting setup_blocklists early))
https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts
https://mirror1.malwaredomains.com/files/justdomains
::: Testing pihole-FTL DNS: FTL started!
::: Testing lighttpd config: Syntax OK
::: All config checks passed, cleared for startup ...
 ::: Docker start setup complete
  [✗] DNS resolution is currently unavailable
EN

回答 1

Stack Overflow用户

发布于 2020-10-02 20:54:32

在这个问题上,你并不孤单。

解决方案在这里- chown: cannot access '/etc/pihole/dhcp.leases': No such file or directory

这也发生在我身上。我使用相同的教程来设置我的集群。如果您还在使用持久卷,请使用ssh连接到您的驱动器并运行这两个命令。

代码语言:javascript
复制
ls -l ----> this will show the owner and user of each file they all should be www-data if not run this cmd
sudo chown -R www-data:www-data pihole from the /mnt/ssd directory described in the tutorial. This will allow you to add more whitelists/blacklists/adlists from the web portal.
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/64146428

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档