I am using core-os on proxmox and I use a butane file that merges other ignition files via http (using source:)
Now I would like to use only local files, so I am replacing source: with local: but I cannot get that to work.
This is the Butane file that I cannot get to work:
variant: fcos
version: 1.5.0
ignition:
config:
merge:
- local: ign/include/ssh.ign
- local: ign/include/add-compose.ign
- local: ign/include/music.ign
- local: ign/include/start-docker.ign
storage:
files:
- path: /etc/hostname
contents:
inline: examplehost
This is the output:
$ butane yaml/example-local.yaml -d /home/dries/workspaces/proxmox-coreos
error at $.ignition.config.merge.1, line 8 col 7: duplicate entry defined
error at $.ignition.config.merge.2, line 9 col 7: duplicate entry defined
error at $.ignition.config.merge.3, line 10 col 7: duplicate entry defined
Error translating config: config generated was invalid
When I use source: it just works
variant: fcos
version: 1.5.0
ignition:
config:
merge:
- source: http://www-fc.familie-dokter.lan/ign/include/ssh.ign
- source: http://www-fc.familie-dokter.lan/ign/include/add-compose.ign
- source: http://www-fc.familie-dokter.lan/ign/include/music.ign
- source: http://www-fc.familie-dokter.lan/ign/include/start-docker.ign
storage:
files:
- path: /etc/hostname
contents:
inline: examplehost
This file converts without a problem to ignition:
$ butane yaml/example.yaml
{"ignition":{"config":{"merge":[{"source":"http://www-fc.familie-dokter.lan/ign/include/ssh.ign"},{"source":"http://www-fc.familie-dokter.lan/ign/include/add-compose.ign"},{"source":"http://www-fc.familie-dokter.lan/ign/include/music.ign"},{"source":"http://www-fc.familie-dokter.lan/ign/include/start-docker.ign"}]},"version":"3.4.0"},"storage":{"files":[{"path":"/etc/hostname","contents":{"compression":"","source":"data:,examplehost"}}]}}
Specification at: Fedora CoreOS v1.6.0 | Butane
From that specification I cannot understand why the behavior is different.
Another thing that bugs me:
When I use merge local: a check is done if the local .ign file exists during ign creation. This check is not performed for merge source:.
It does not make sense to check this at .ign creation. I create the .ign files on my desktop, but use them on my proxmox server (which means when I actually use them, the files are at another location)