Creates a share, replacing any existing share with the same name.
Install-Share [-Name] <String> [-Path] <String> [[-Description] <String>] [[-Permissions] <String[]>] [<CommonParameters>]
Creates a new Windows SMB share, or replaces an existing share with the same name. Optionally grants permissions on that share. Unfortunately, there isn't a way in Carbon to set permissions on a share after it is created. Send us the code!
Permissions don't apply to the file system. They only apply to the share. Use Grant-Permissions
to grant file system permissions.
Name | Type | Description | Required? | Pipeline Input | Default Value |
---|---|---|---|---|---|
Name | String | The share's name. | true | false | |
Path | String | The path to the share. | true | false | |
Description | String | A description of the share | false | false | |
Permissions | String[] | The share's permissions. Each item should be of the form: user,[READ | CHANGE | FULL] | false | false |
Install-Share -Name TopSecretDocuments -Path C:\TopSecret -Description 'Share for our top secret documents.' -Permissions "Everyone,Read","Analysts,FULL"
Shares the C:\TopSecret directory as TopSecretDocuments
and grants Everyone
read access and Analysts
full control.