Skip to content

[BUG] Creating a salt-master vm on azurearm fails #58096

Closed as not planned
Closed as not planned

Description

@markododa

following the cloud map guide, specifically the part on setting up new salt master https://docs.saltstack.com/en/latest/topics/cloud/map.html#setting-up-new-salt-masters, i have the map file:

azure_ubuntu:
  - smvm:
      make_master: True

backed up by the following profile:

azure_ubuntu:
  provider: my-azurearm-config
  image: Canonical|UbuntuServer|18.04-LTS|latest
  size: Basic_A0
  #location: westus
  #network: my_network
  #subnet: subnet
  #resource_group: my_rg
  allocate_public_ip: True
  ssh_username: azureuser
  ssh_publickeyfile: /root/.ssh/id_rsa.pub
  ssh_keyfile: /root/.ssh/id_rsa
  disable_password_authentication: True

Launching a regular instance works just fine however when make_master is True, salt-cloud trows the following error

[ERROR   ] There was a query error: dictionary update sequence element #0 has length 1; 2 is required
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/salt/cloud/cli.py", line 352, in run
    ret = mapper.run_map(dmap)
  File "/usr/lib/python3/dist-packages/salt/cloud/__init__.py", line 2126, in run_map
    out = self.create(master_profile, local_master=local_master)
  File "/usr/lib/python3/dist-packages/salt/cloud/__init__.py", line 1242, in create
    output = self.clouds[func](vm_)
  File "/usr/lib/python3/dist-packages/salt/cloud/clouds/azurearm.py", line 1362, in create
    ret = __utils__["cloud.bootstrap"](vm_, __opts__)
  File "/usr/lib/python3/dist-packages/salt/utils/cloud.py", line 547, in bootstrap
    master_conf = master_config(opts, vm_)
  File "/usr/lib/python3/dist-packages/salt/utils/cloud.py", line 361, in master_config
    "master", vm_, opts, default={}, search_global=True
ValueError: dictionary update sequence element #0 has length 1; 2 is required

Activity

  1. added
    bug
    on Jul 30, 2020
  2. markododa commented on Jul 30, 2020

    @markododa
    Author

    However it seems like just adding a simple master section fixes it

    azure_ubuntu:
      - master:
          make_master: True
          master:
            user: root
            interface: 0.0.0.0
    
  3. modified the milestones: Blocked, Follow up on Aug 3, 2020
  4. added
    pending-discussion
    documentation
    on Aug 3, 2020
  5. cmcmarrow commented on Aug 3, 2020

    @cmcmarrow
    Contributor

    @markododa looks like salt expects the master section and does not add defaults if missing. Is the documentations not clear about this? Do you think the documentations needs to make this more clear?

  6. markododa commented on Aug 3, 2020

    @markododa
    Author
  7. added
    severity-high
    and removed
    pending-discussion
    on Aug 12, 2020
  8. added
    Phosphorus v3005.0
    on Jun 18, 2021
  9. removed this from the Approved milestone on Jun 18, 2021
  10. 1 remaining item

  11. removed
    Phosphorus v3005.0
    on Mar 30, 2022
  12. added
    help-wanted
    on Apr 11, 2022
  13. dwoz commented on Oct 23, 2026

    @dwoz
    Contributor

    Closing as part of a backlog cleanup — this issue was filed without a Salt versions-report, so there's no explicit version attached to compare against.

    If you (or anyone else) can still reproduce this on 3008.3 or later, please comment with:

    • A fresh reproduction
    • The output of salt --versions-report

    and the issue will be reopened. The original reporter can also reopen directly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugdocumentationhelp-wantedseverity-hightime-estimate-sprint

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions