First using formulas: template specified incorrectly

50 views
Skip to first unread message

Jeff Abrahamson

unread,
Jan 19, 2018, 8:54:29 AM1/19/18
to salt-...@googlegroups.com
Salt newbie here, I'm starting to use formulas.  And not understanding
something.

I'm trying to use the openssh formula (which I've cloned, but here I'll
use the original URL).

    https://github.com/saltstack-formulas/openssh-formula

I modify /etc/salt/master thus:

    gitfs_remotes:
      - https://github.com/saltstack-formulas/openssh-formula.git

and then I have /srv/salt/system/init.sls which includes these three
lines (among others unrelated):

    include:
      - openssh
      - openssh.config

Finally, I have some pillar data for the sshd config in
/srv/pillar/system/sshd.sls:

    sshd_config:
      PermitRootLogin: 'no'
      PasswordAuthentication: 'no'
      AllowUsers:
    {% for user, user_data in pillar.get('human_users', {}).items() %}
    - {{user}}
    {% endfor %}

And then I try to make it all go, but it doesn't:

    [T] ubuntu@ubuntu-xenial:vagrant $ sudo salt-call --local
state.highstate
    [ERROR   ] Template was specified incorrectly: False
    [ERROR   ] Template was specified incorrectly: False
    local:
    Data failed to compile:
    ----------
    Specified SLS openssh in saltenv base is not available on the salt
master or through a configured fileserver
    ----------
    Specified SLS openssh.config in saltenv base is not available on the
salt master or through a configured fileserver
    [T] ubuntu@ubuntu-xenial:vagrant $

While it's complaining about a bad template specification, it doesn't
seem to be the AllowUsers clause, because commenting that out doesn't
change the error.  Commenting out the three lines of include openssh, on
the other hand, stops the error message.

Any pointers on what I'm doing wrong?

--

Jeff Abrahamson
+33 6 24 40 01 57
+44 7920 594 255

http://p27.eu/jeff/


Reply all
Reply to author
Forward
0 new messages