Initial manifest missing

已查看 28 次
跳至第一个未读帖子

Dániel Fancsali

未读,
2020年5月2日 08:42:182020/5/2
收件人 cdist-configuration-management
Hello,

Your projects cought my eye, it seems to be interesting take on the config management problem. Not having to use yet another slightly different DSL, is definitely a big pro. So I figured I'll give it a go. I've set up a debian VM, set up a port forward from host 2222 to guest 22, and put all the details in my .ssh/config:

Host debian
  HostName localhost
  Port 2222
  IdentityFile /home/me/.ssh/cdist_rsa


I set up the quickstart example in by installing cdist wth pip, and setting up the config dir in ~/.cdist, but when I try to run the configure command, I get a spectacular error:

cdist config -v debian
...
Initial manifest missing: /var/folders/wt/c08nmfn54mlb5bvy7_fz69h5l9h12p/T/tmpf_9dj5yk/421aa90e079fa326b6494f812ad13e79/data/conf/manifest/init'

And the the whole config run - obviously - fails.

Am I missign something? Any pointers will be greatly appreciated.

Regards,
Daniel

Darko Poljak

未读,
2020年5月2日 09:14:562020/5/2
收件人 cdist-configuration-management
Daniel,

I am glad you got to the cdist :)

I will try to help you with your *init*ial problem.

Are you mentioning this quickstart: https://www.cdi.st/manual/latest/cdist-quickstart.html?

Have set up/create your initial manifest?
That would be this line from the above link:
    echo '__file /etc/cdist-configured' > cdist/conf/manifest/init

You can read about *init* manifest/manifests here: https://www.cdi.st/manual/latest/cdist-manifest.html.
Init manifest is cdist starting point, a place where you define what to do for a particular target host(s).
Also take a look at other documentation chapters.
I know, starting with cdist can be slow at the beginning, but you'll start to love it ;)

Have fun,
Darko

Dániel Fancsali

未读,
2020年5月7日 07:13:002020/5/7
收件人 Darko Poljak、cdist-configuration-management
Hello,

Thank you very much for your quick reply.

Had another go, but no luck, unfortunately.

As far as I can tell, it is there:
$ cat ~/.cdist/conf/manifest/init
__file /etc/cdist-configured


But running the command gives me the same error (went really verbose this time):
$ cdist config -n -vvv debian
VERBOSE: cdist: version 6.5.5
DEBUG: inventory: Host 'debian' not found, skipped
DEBUG: config: Base root path for target host "debian" is "/var/folders/wt/c08nmfn54mlb5bvy7_fz69h5l9h12p/T/tmpbv056x0m/6e9552c9bd8e61c8f277c21220160234"
DEBUG: debian: remote_exec for host "debian": ssh -o User=root -o ControlPath=/var/folders/wt/c08nmfn54mlb5bvy7_fz69h5l9h12p/T/tmp5wf5q7cy/s  -o ControlMaster=auto  -o ControlPersist=2h
DEBUG: debian: remote_copy for host "debian": scp -o User=root -q -o ControlPath=/var/folders/wt/c08nmfn54mlb5bvy7_fz69h5l9h12p/T/tmp5wf5q7cy/s  -o ControlMaster=auto  -o ControlPersist=2h
DEBUG: debian: address family: 0
<waits for a rather long time here>
WARNING: debian: Could not derive host_name for debian, $host_name will be empty. Error is: [Errno 8] nodename nor servname provided, or not known
DEBUG: debian: derived host_fqdn for host "debian": debian
DEBUG: debian: target_host for host "debian": ('debian', '', 'debian')
INFO: debian: Starting dry run
DEBUG: debian: Checking conf_dir /Users/f7745312/ispmail/venv/lib/python3.7/site-packages/cdist/conf ...
DEBUG: debian: Checking conf_dir /Users/f7745312/.cdist ...
VERBOSE: debian: Running global explorers
DEBUG: debian: Running global explorers sequentially
ERROR: debian: 'Initial manifest missing: /var/folders/wt/c08nmfn54mlb5bvy7_fz69h5l9h12p/T/tmpbv056x0m/6e9552c9bd8e61c8f277c21220160234/data/conf/manifest/init'

Error processing initial manifest
=================================
path: /var/folders/wt/c08nmfn54mlb5bvy7_fz69h5l9h12p/T/tmpbv056x0m/6e9552c9bd8e61c8f277c21220160234/data/conf/manifest/init


VERBOSE: config: Total processing time for 1 host(s): 69.68427991867065
ERROR: cdist: Failed to configure the following hosts: debian

The only thing, that's rather puzzling there (besides the manifest missing) is the warning about the hostiname. But the fact, that it seems to be able to connect (confirmed in the auth.log on the VM), and run the explorers makes it seem like a red herring.

Checked the path on the master machine (as in the one that should be talking to debian, and configure it):
$ ls /var/folders/wt/c08nmfn54mlb5bvy7_fz69h5l9h12p/T/tmptb7x3s2f/6e9552c9bd8e61c8f277c21220160234/data/conf/manifest
sample-from-distribution

So, it's correct: it is missing. Can't really wrap my head around this. How exaclty should it get from ~/.cdist/... to /var/folders/.../manifest?

Regards,
Daniel

--
You received this message because you are subscribed to the Google Groups "cdist-configuration-management" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cdist-configuration-m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/cdist-configuration-management/6622b200-d0cc-4796-b9fc-e941ddc83ca1%40googlegroups.com.
回复全部
回复作者
转发
0 个新帖子