Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Organization parameter for Software Repository resources #231

Open
sandkum5 opened this issue Dec 21, 2022 · 2 comments
Open

Add Organization parameter for Software Repository resources #231

sandkum5 opened this issue Dec 21, 2022 · 2 comments

Comments

@sandkum5
Copy link

Bug Report Checklist

The organization parameter is missing for Firmware links / SCU / OS Repositories / OS Configuration files repositories.

Affected Resources:
intersight_firmware_server_configuration_utility_distributable
intersight_softwarerepository_operating_system_file
intersight_os_configuration_file
intersight_firmware_upgrade

When we create Firmware links or SCU or OS or OS Configuration file repositories in Intersight GUI, we have the option to choose an Organization. However, a similar option is missing from Terraform code.

Users can't create these repositories under any other org. By default, these are getting created under "default" org. Additionally, this option can't be changed once the resource is created.

Affected Intersight provider version: 1.0.34

@sandkum5 sandkum5 changed the title Add Organization parameter under repo resources Add Organization parameter for Software Repository resources Dec 21, 2022
@scotttyso
Copy link

@mohamuni
Copy link
Contributor

Organization can be associated with Software repository by selecting a catalog under required organization. In hierarchy of relationship of Software repository with Organization is that Software Repository has relationship with Catalog which in turns has relationship with Organization.

Organization can be added to software repository as shown below

resource "intersight_firmware_server_configuration_utility_distributable" "scu1" {
  name = "SCU-6.0.4c nfs"
  nr_source {
    object_type = "softwarerepository.CifsServer"
    additional_properties = jsonencode({
      FileLocation = "1.1.1.1/iso.iso"
      RemoteIp     = "1.1.1.1"
      RemoteShare  = "/path/to/remote/share"
      RemoteFile   = "/path/to/remote/file"
      Username     = "user"
      Password     = "ChangeMe"
      MountOption  = "sec=ntlm"
    })
  }
  vendor     = "Cisco"
  nr_version = "6.0.(4c)"
  supported_models = [
    "C-series"
  ]
  description = "Cisco SCU-6.0(4c)"
  catalog {
    moid        = data.intersight_softwarerepository_catalog.catalog.results[0].moid
    object_type = "softwarerepository.Catalog"
  }
}

data "intersight_organization_organization" "organization" {
  name = "default"
}

data "intersight_softwarerepository_catalog" "catalog"{
  organization {
    class_id = "organization.Organization"
    moid = data.intersight_organization_organization.organization.id
  }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants