-
I'm trying to get Inadyn (dynamic DNS client) setup with ---
apiVersion: v1
kind: Pod
metadata:
name: indadyn-pod
spec:
hostname: inadyn-pod
securityContext:
seLinuxOptions:
type: spc_t
containers:
- name: inadyn
image: docker.io/troglobit/inadyn:latest
volumeMounts:
- name: inadyn-config
mountPath: /etc
volumes:
- name: inadyn-config
configMap:
name: inadyn-config
---
apiVersion: v1
kind: ConfigMap
metadata:
name: inadyn-config
data:
inadyn.conf: |
period = 300
user-agent = Mozilla/5.0
provider cloudflare.com {
username = zone.name
password = REDACTED
hostname = hostname.zone.name
ttl = 1
proxied = false
} My problem is, it's saying that the config file can't be found.
I looked in the |
Beta Was this translation helpful? Give feedback.
Replies: 7 comments 8 replies
-
Can you remove the inadyn-config volume and start again? |
Beta Was this translation helpful? Give feedback.
-
@Luap99 @umohnani8 PTAL |
Beta Was this translation helpful? Give feedback.
-
@Luap99 @umohnani8 Sorry to bother you, but I was still having this issue. I'm pretty stumped at this point. |
Beta Was this translation helpful? Give feedback.
-
I think you might need to use subPath - change the mountPath to /etc/inadyn.conf and add 'subPath: inadyn.conf'. Here is an example I've been using for testing kube play on FreeBSD - adjust the paths and image name to try it on Linux.
|
Beta Was this translation helpful? Give feedback.
-
The data section of the ConfigMap should not be indented - it should be at
the same level as the metadata section.
…On Fri, 28 Jul 2023 at 22:17, PopeRigby ***@***.***> wrote:
Thank you for your help. I tried using subPath, but now I'm getting this
confusing error:
[starting container aabac1bc2209b852f8bd1de24c1a5b8351256f53997ef33949e466a5d91d19d0: no such file or directory]
Pod:
25336882dc8adb0a3feb2fee09b760d0db8da3ff44f11003873630404620fb01
Container:
aabac1bc2209b852f8bd1de24c1a5b8351256f53997ef33949e466a5d91d19d0
starting container aabac1bc2209b852f8bd1de24c1a5b8351256f53997ef33949e466a5d91d19d0: no such file or directory
Error: failed to start 1 containers
This is my updated YAML:
---apiVersion: v1kind: Podmetadata:
name: indadyn-podspec:
hostname: inadyn-pod
securityContext:
seLinuxOptions:
type: spc_t
containers:
- name: inadyn
image: docker.io/troglobit/inadyn:latest
volumeMounts:
- name: inadyn-config
mountPath: /etc/inadyn.conf
subPath: inadyn.conf
volumes:
- name: inadyn-config
configMap:
name: inadyn-config
---apiVersion: v1kind: ConfigMapmetadata:
name: inadyn-config
data:
inadyn.conf: | period = 300 user-agent = Mozilla/5.0 provider cloudflare.com { username = REDACTED password = REDACTED hostname = REDACTED ttl = 1 proxied = false }
—
Reply to this email directly, view it on GitHub
<#18967 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOTJJH6475LHHAWLHNWRTXSQT7BANCNFSM6AAAAAAZPOEWG4>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
I just tried using your exact YAML on a fedora VM with podman-4.5.0 both
rootless and rootfull and it seems to work for me. Possible try 'podman
volume rm inadyn-config' to make sure nothing from previous attempts is
confusing us?
Doug.
…On Sat, 29 Jul 2023 at 18:51, PopeRigby ***@***.***> wrote:
Thank you. Now it's saying this:
[starting container 83fcc3758eaa07b24e7f849218f150e3c249c007dc66424725e23cf950b502c2: subpath "inadyn.conf" is outside of the volume "/home/cassidy/.local/share/containers/storage/volumes/inadyn-config/_data"]
Pod:
adc385b751500742f9564a4223b44ea80e07d23a50759130d545d0ba7fec0ae6
Container:
83fcc3758eaa07b24e7f849218f150e3c249c007dc66424725e23cf950b502c2
starting container 83fcc3758eaa07b24e7f849218f150e3c249c007dc66424725e23cf950b502c2: subpath "inadyn.conf" is outside of the volume "/home/cassidy/.local/share/containers/storage/volumes/inadyn-config/_data"
Error: failed to start 1 containers
Updated YAML again:
---apiVersion: v1kind: Podmetadata:
name: indadyn-podspec:
hostname: inadyn-pod
securityContext:
seLinuxOptions:
type: spc_t
containers:
- name: inadyn
image: docker.io/troglobit/inadyn:latest
volumeMounts:
- name: inadyn-config
mountPath: /etc/inadyn.conf
subPath: inadyn.conf
volumes:
- name: inadyn-config
configMap:
name: inadyn-config
---apiVersion: v1kind: ConfigMapmetadata:
name: inadyn-configdata:
inadyn.conf: | period = 300 user-agent = Mozilla/5.0 provider cloudflare.com { username = haddock.cc password = mCI2Q4YPDlpAHor60jcvAuY67vBR9YYMVt4vHDvt hostname = haddock.cc ttl = 1 proxied = false }
—
Reply to this email directly, view it on GitHub
<#18967 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOTJJIS65E6X6YXOYE5RDXSVESRANCNFSM6AAAAAAZPOEWG4>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
I'm not sure what to suggest - here is a transcript running your yaml file
on a rootless podman. Also, I think you shared your cloudflare password
earlier so you should probably change that.
…---
apiVersion: v1
kind: Pod
metadata:
name: indadyn-pod
spec:
hostname: inadyn-pod
securityContext:
seLinuxOptions:
type: spc_t
containers:
- name: inadyn
image: docker.io/troglobit/inadyn:latest
volumeMounts:
- name: inadyn-config
mountPath: /etc/inadyn.conf
subPath: inadyn.conf
volumes:
- name: inadyn-config
configMap:
name: inadyn-config
---
apiVersion: v1
kind: ConfigMap
metadata:
name: inadyn-config
data:
inadyn.conf: |
period = 300
user-agent = Mozilla/5.0
provider cloudflare.com {
username = haddock.cc
password = <redacted>
hostname = haddock.cc
ttl = 1
proxied = false
}
***@***.*** ~]$
***@***.*** ~]$ podman kube play test.yaml
Trying to pull docker.io/troglobit/inadyn:latest...
Getting image source signatures
Copying blob 8e07e8252c09 done
Copying blob 11c46839e0df done
Copying blob c34586335e60 done
Copying blob 31e352740f53 done
Copying config d7efdfbc17 done
Writing manifest to image destination
Storing signatures
Pod:
4cd844d3790fc9aff23296986bc122c64b22cfc342f431214d70fa8a36c68951
Container:
6a84b61ab2f92f8a8255677d1425301d1b4a050295eca01fa909ae178b4fe28a
***@***.*** ~]$ podman ps
CONTAINER ID IMAGE COMMAND CREATED
STATUS PORTS NAMES
9d54388f4e9a localhost/podman-pause:4.5.0-1681486976 2
minutes ago Up 23 seconds 4cd844d3790f-infra
6a84b61ab2f9 docker.io/troglobit/inadyn:latest About a
minute ago Up 14 seconds indadyn-pod-inadyn
***@***.*** ~]$ podman logs -l
inadyn[1]: In-a-dyn version 2.12.0-dev -- Dynamic DNS update client.
inadyn[1]: Guessing DDNS plugin ***@***.***' from '
cloudflare.com'
inadyn[1]: Update forced for alias haddock.cc, new IP# <redacted>
inadyn[1]: Updating IPv4 cache for haddock.cc
***@***.*** ~]$ podman kube down test.yaml
Pods stopped:
4cd844d3790fc9aff23296986bc122c64b22cfc342f431214d70fa8a36c68951
Pods removed:
4cd844d3790fc9aff23296986bc122c64b22cfc342f431214d70fa8a36c68951
Secrets removed:
Volumes removed:
***@***.*** ~]$
On Sun, 30 Jul 2023 at 18:47, PopeRigby ***@***.***> wrote:
I've been removing it every time, so I have no idea what's happening. I'm
on Fedora IoT with Podman 4.5.1.
—
Reply to this email directly, view it on GitHub
<#18967 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABOTJOZAYYEGGETQUOWFN3XS2M4DANCNFSM6AAAAAAZPOEWG4>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
Hey @poperigby, I also tried running your yaml on a Fedora machine and it works fine for me. I didn't use the subPath option as that is not needed for your use case, so please remove that. One thing I would suggest is ensuring that there are no remnants of the volume or containers from previous runs, can you do an
rm
on your containers, pods, and volumes. If you don't mind losing all your podman containers and images, doing apodman system reset
will reset everything to a new state.Once you do that, can you try running the yaml again (without the
subPath
field) withpodman kube play
and see if it works for you.