saltstack-formulas / lxd-formula

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

Profile names may not contain slashes #7

Closed noelmcloughlin closed 6 years ago

noelmcloughlin commented 6 years ago

Seeing this error on following README examples. Raised a PR #6

  ID: lxd_profile_local_xenial_amd64
    Function: lxd_profile.present
        Name: xenial/amd64
      Result: False
     Comment: An exception occurred in this state: Traceback (most recent call last):
                File "/usr/lib/python2.7/dist-packages/salt/state.py", line 1851, in call
                  **cdata['kwargs'])
                File "/usr/lib/python2.7/dist-packages/salt/loader.py", line 1795, in wrapper
                  return f(*args, **kwargs)
                File "/var/cache/salt/minion/extmods/states/lxd_profile.py", line 148, in present
                  verify_cert
                File "/var/cache/salt/minion/extmods/modules/lxd.py", line 2029, in profile_create
                  profile = client.profiles.create(name, config, devices)
                File "/usr/local/lib/python2.7/dist-packages/pylxd/models/profile.py", line 60, in create
                  client.api.profiles.post(json=profile)
                File "/usr/local/lib/python2.7/dist-packages/pylxd/client.py", line 134, in post
                  self._assert_response(response, allowed_status_codes=(200, 201, 202))
                File "/usr/local/lib/python2.7/dist-packages/pylxd/client.py", line 91, in _assert_response
                  raise exceptions.LXDAPIException(response)
              LXDAPIException: Profile names may not contain slashes
     Started: 05:18:56.849307
    Duration: 12.954 ms
     Changes:   
jochumdev commented 6 years ago

Profiles may not contain slashes but images are fine, not sure where i messed that up will look into this.

jochumdev commented 6 years ago

I can't find a case in the docs where i have the image name "xenial/amd64" in a profile.