saltstack-formulas / mongodb-formula

http://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html
Other
31 stars 120 forks source link

State 'mongodb' in SLS 'mongodb' is not formed as a list #46

Closed zwiebelspaetzle closed 7 years ago

zwiebelspaetzle commented 7 years ago

Hello,

I'm using a very slightly modified version of the example pillar, but when I try to run salt (sudo salt-call --local state.apply -l debug), I get the following error:

local:
    Data failed to compile:
----------
    State 'mongodb' in SLS 'mongodb' is not formed as a list
----------
    State 'mongodb' in SLS 'mongodb' is not formed as a list

The "not formed as a list" error is repeated 11 times. My pillar file passes a yamllint.com check. Any suggestions why salt is rejecting it?

Thanks!


/srv/salt/pillar/mongodb.sls:

## For versions of Mongo that use the YAML format for configuration, use the
## following. All entries in mongod_settings are written to the config file
## verbatim. The storage:dbPath and systemLog:path entries are required in
## this usage and take precedence over db_path at the top level (see references
## in mongodb/init.sls).
mongodb:
  use_repo: True
  version: 3.2 # use oldstable in for 1.8 - 2.6
  repo_component: main
  mongodb_package: mongodb-org
  mongodb_user: mongodb
  mongodb_group: mongodb
  mongod: mongod
  conf_path: /etc/mongod.conf
  log_path: /mongodb/log
  db_path: /mongodb/data
  mongod_settings:
    systemLog:
      destination: file
      logAppend: true
      path: /var/log/mongodb/mongod.log
    storage:
      dbPath: /var/lib/mongodb
      journal:
        enabled: true
    net:
      port: 27017
      bindIp: 0.0.0.0
    setParameter:
      textSearchEnabled: true

/srv/salt/minion.yml:

master: localhost

file_client: local

state_verbose: True

gitfs_provider: gitpython

fileserver_backend:
  - roots
  - git

gitfs_remotes:
  - https://github.com/saltstack-formulas/node-formula.git
  - https://github.com/saltstack-formulas/mongodb-formula.git
  - https://github.com/saltstack-formulas/mysql-formula.git

file_roots:
  base:
    - /srv/salt/
    - /srv/salt/roots/
    - /srv/salt/pillar/

pillar_roots:
  base:
    - /srv/salt/pillar/

/srv/salt/pillar/top.sls:

base:
  '*':
    - node
    - mongodb