Skip to content

DSC Install required prerequisites - setup current enviroment #1548

@mimachniak

Description

@mimachniak

Summary of the new feature / enhancement

DSC Install required prerequisites – as parameter or force in installation process

Hello I like to suggest option to install prerequisites for DSC engine similar to Winget as it export configuration to DSC file, as new PSResourceGet PR contain PowerShell/PSResourceGet#1950 integration with PowerShell gallery and MAR it will be nice to have not manually install this dsc additionl things as a separated process or manual copy those files across environment.

Proposed technical implementation details (optional)

Technical propusal for this

dsc setup --force  #silent with overrride option

or 

dsc setup --install # prompt interactive with select [Y/N]

Base on for example perquisites json file or schema like this it will install required components

{
    "prequisites": [
    {
        "Name": "PowerShell 7.0+",
        "SupportedPlatformOS": ["Windows", "Linux"],
        "Install_options": {
            "Windows": [
                "winget list --id Microsoft.PowerShell --upgrade-available"
            ],
            "Linux": [
                "sudo apt-get update",
                "sudo apt-get install -y powershell"
            ]
        },
        "dependency": "None"
    },
    {
        "Name": "PSResourceGet",
        "SupportedPlatformOS": ["Windows", "Linux"],
        "Install_options": {
            "Windows": [
                "Install-PSResource -Name Microsoft.PowerShell.PSResourceGet -Version '1.3.0-preview1' -Prerelease"
            ],
            "Linux": [
                "Install-PSResource -Name Microsoft.PowerShell.PSResourceGet -Version '1.3.0-preview1' -Prerelease"
            ]
        },
        "dependency": "PowerShell 7.0+"
    }
]
}
    

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions