Set-FilesRemoteServer
Update Remote Server.
Syntax
Id (Default)
InputObject
Description
Update Remote Server.
The command accepts remote servers from the pipeline as -InputObject, and uses each one's Id and the connection that fetched it.
When given -InputObject, the command updates that object with the values Files.com returns and writes it.
The command supports -WhatIf, which describes the change without sending it to Files.com, and -Confirm, which asks before sending it. It asks for confirmation by default; use -Confirm:$false in scripts that have already decided.
Examples
Example 1: Update Remote Server
Writes the remote server as Files.com returns it.
Example 2: Act on remote servers from the pipeline
Takes the remote server from the pipeline and uses its Id and connection.
Example 3: Preview the change
Describes the change without sending anything to Files.com.
Parameters
-Id
Remote Server ID.
- Type:
System.Int64 - Parameter sets:
Id(required, position 0)
-Password
Password, if needed. Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-PrivateKey
Private key, if needed. Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-PrivateKeyPassphrase
Passphrase for private key if needed. Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-ResetAuthentication
Reset authenticated account?
- Type:
System.Boolean - Parameter sets:
Id,InputObject
-SharepointClientCertificate
SharePoint: PEM-encoded certificate and unencrypted private key for app-only authentication. Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-SharepointClientSecret
SharePoint: Microsoft Entra application client secret for app-only authentication. Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-SslCertificate
SSL client certificate.
- Type:
System.String - Parameter sets:
Id,InputObject
-AwsSecretKey
AWS: secret key. Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-AzureBlobStorageAccessKey
Azure Blob Storage: Access Key Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-AzureBlobStorageSasToken
Azure Blob Storage: Shared Access Signature (SAS) token Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-AzureFilesStorageAccessKey
Azure File Storage: Access Key Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-AzureFilesStorageSasToken
Azure File Storage: Shared Access Signature (SAS) token Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-BackblazeB2ApplicationKey
Backblaze B2 Cloud Storage: applicationKey Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-BackblazeB2KeyId
Backblaze B2 Cloud Storage: keyID
- Type:
System.String - Parameter sets:
Id,InputObject
-CloudflareSecretKey
Cloudflare: Secret Key Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-FilebaseSecretKey
Filebase: Secret Key Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-GoogleCloudStorageCredentialsJson
Google Cloud Storage: JSON file that contains the private key. To generate see https://cloud.google.com/storage/docs/json_api/v1/how-tos/authorizing#APIKey Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-GoogleCloudStorageS3CompatibleSecretKey
Google Cloud Storage: S3-compatible secret key Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-LinodeSecretKey
Linode: Secret Key Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-S3CompatibleSecretKey
S3-compatible: Secret Key Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-WasabiSecretKey
Wasabi: Secret Key Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-AllowRelativePaths
Allow relative paths in SFTP. If true, paths will not be forced to be absolute, allowing operations relative to the user's home directory.
- Type:
System.Boolean - Parameter sets:
Id,InputObject
-AwsAccessKey
AWS Access Key.
- Type:
System.String - Parameter sets:
Id,InputObject
-AzureBlobStorageAccount
Azure Blob Storage: Account name
- Type:
System.String - Parameter sets:
Id,InputObject
-AzureBlobStorageContainer
Azure Blob Storage: Container name
- Type:
System.String - Parameter sets:
Id,InputObject
-AzureBlobStorageDnsSuffix
Azure Blob Storage: Custom DNS suffix
- Type:
System.String - Parameter sets:
Id,InputObject
-AzureBlobStorageHierarchicalNamespace
Azure Blob Storage: Does the storage account has hierarchical namespace feature enabled?
- Type:
System.Boolean - Parameter sets:
Id,InputObject
-AzureFilesStorageAccount
Azure Files: Storage Account name
- Type:
System.String - Parameter sets:
Id,InputObject
-AzureFilesStorageDnsSuffix
Azure Files: Custom DNS suffix
- Type:
System.String - Parameter sets:
Id,InputObject
-AzureFilesStorageShareName
Azure Files: Storage Share name
- Type:
System.String - Parameter sets:
Id,InputObject
-BackblazeB2Bucket
Backblaze B2 Cloud Storage: Bucket name
- Type:
System.String - Parameter sets:
Id,InputObject
-BackblazeB2S3Endpoint
Backblaze B2 Cloud Storage: S3 Endpoint
- Type:
System.String - Parameter sets:
Id,InputObject
-BufferUploads
If set to always, uploads to this server will be uploaded first to Files.com before being sent to the remote server. This can improve performance in certain access patterns, such as high-latency connections. It will cause data to be temporarily stored in Files.com. If set to auto, we will perform this optimization if we believe it to be a benefit in a given situation.
- Type:
System.String - Parameter sets:
Id,InputObject
-CloudflareAccessKey
Cloudflare: Access Key.
- Type:
System.String - Parameter sets:
Id,InputObject
-CloudflareBucket
Cloudflare: Bucket name
- Type:
System.String - Parameter sets:
Id,InputObject
-CloudflareEndpoint
Cloudflare: endpoint
- Type:
System.String - Parameter sets:
Id,InputObject
-Description
Internal description for your reference
- Type:
System.String - Parameter sets:
Id,InputObject
-DropboxTeams
Dropbox: If true, list Team folders in root?
- Type:
System.Boolean - Parameter sets:
Id,InputObject
-EnableDedicatedIps
true if remote server only accepts connections from dedicated IPs
- Type:
System.Boolean - Parameter sets:
Id,InputObject
-FilebaseAccessKey
Filebase: Access Key.
- Type:
System.String - Parameter sets:
Id,InputObject
-FilebaseBucket
Filebase: Bucket name
- Type:
System.String - Parameter sets:
Id,InputObject
-FilesApiKey
Files.com direct link: API key used once to pair the remote server. Give a SecureString, such as one from Read-Host -AsSecureString or Get-Secret; text typed on the command line, even inside ConvertTo-SecureString, stays in command history.
- Type:
System.Security.SecureString - Parameter sets:
Id,InputObject
-FilesAgentPermissionSet
Agent file permissions: read_only, write_only, or read_write. Files.com writes this value as permission_set in the configuration file generated for this Remote Server. Setting it on Create or Update changes the generated file, not a running Agent. The Agent enforces the permissions in its local configuration file, controlled by the host's system administrator, and reports them at registration, replacing the stored value.
- Type:
System.String - Parameter sets:
Id,InputObject
-FilesAgentRoot
Agent local root path. Files.com writes this value as root in the configuration file generated for this Remote Server. Setting it on Create or Update changes the generated file, not a running Agent. The Agent enforces the root in its local configuration file, controlled by the host's system administrator, and reports it at registration, replacing the stored value.
- Type:
System.String - Parameter sets:
Id,InputObject
-FilesAgentVersion
Files.com Agent version reported by the Agent at each registration, replacing the stored value. This field is not included in the generated Agent configuration file. Setting it on Create or Update does not update the running Agent.
- Type:
System.String - Parameter sets:
Id,InputObject
-OutboundAgentId
Route traffic to outbound on a files-agent
- Type:
System.Int64 - Parameter sets:
Id,InputObject
-CustomDomainId
Custom Domain ID whose dedicated IP addresses are selected when this Remote Server uses dedicated IPs. Must be available to this Remote Server's workspace. Requires enable_dedicated_ips and cannot be combined with an outbound Agent. Set to null to use the site's default dedicated IPs.
- Type:
System.Int64 - Parameter sets:
Id,InputObject
-GoogleCloudStorageAuthenticationMethod
Google Cloud Storage: Authentication method. Can be json, hmac, or oauth.
- Type:
System.String - Parameter sets:
Id,InputObject
-GoogleCloudStorageBucket
Google Cloud Storage: Bucket Name
- Type:
System.String - Parameter sets:
Id,InputObject
-GoogleCloudStorageOauthScope
Google Cloud Storage: OAuth scope. Can be https://www.googleapis.com/auth/devstorage.read_only or https://www.googleapis.com/auth/devstorage.read_write.
- Type:
System.String - Parameter sets:
Id,InputObject
-GoogleCloudStorageProjectId
Google Cloud Storage: Project ID
- Type:
System.String - Parameter sets:
Id,InputObject
-GoogleCloudStorageS3CompatibleAccessKey
Google Cloud Storage: S3-compatible Access Key.
- Type:
System.String - Parameter sets:
Id,InputObject
-Hostname
Hostname or IP address. For Agent Remote Servers, the Agent reports the hostname it connects from at each registration, replacing the stored value. This field is not included in the generated Agent configuration file. Setting it on Create or Update does not change the running Agent.
- Type:
System.String - Parameter sets:
Id,InputObject
-LinodeAccessKey
Linode: Access Key
- Type:
System.String - Parameter sets:
Id,InputObject
-LinodeBucket
Linode: Bucket name
- Type:
System.String - Parameter sets:
Id,InputObject
-LinodeRegion
Linode: region
- Type:
System.String - Parameter sets:
Id,InputObject
-MaxConnections
Max number of parallel connections. Ignored for S3 connections (we will parallelize these as much as possible).
- Type:
System.Int64 - Parameter sets:
Id,InputObject
-Name
Internal name for your reference
- Type:
System.String - Parameter sets:
Id,InputObject
-OneDriveAccountType
OneDrive: Either personal or business_other account types
- Type:
System.String - Parameter sets:
Id,InputObject
-PinToSiteRegion
If true, we will ensure that all communications with this remote server are made through the primary region of the site. This setting can also be overridden by a site-wide setting which will force it to true.
- Type:
System.Boolean - Parameter sets:
Id,InputObject
-Port
Port for remote server. For Agent Remote Servers, the Agent reports its downstream proxy port at each registration, replacing the stored value. This field is not included in the generated Agent configuration file. Setting it on Create or Update does not change the running Agent.
- Type:
System.Int64 - Parameter sets:
Id,InputObject
-UploadStagingPath
Upload staging path. Applies to SFTP only. If a path is provided here, files will first be uploaded to this path on the remote folder and the moved into the final correct path via an SFTP move command. This is required by some remote MFT systems to emulate atomic uploads, which are otherwise not supoprted by SFTP.
- Type:
System.String - Parameter sets:
Id,InputObject
-RemoteServerCredentialId
ID of Remote Server Credential, if applicable.
- Type:
System.Int64 - Parameter sets:
Id,InputObject
-S3AssumeRoleArn
AWS IAM Role ARN for AssumeRole authentication.
- Type:
System.String - Parameter sets:
Id,InputObject
-S3AssumeRoleDurationSeconds
Session duration in seconds for AssumeRole authentication (900-43200).
- Type:
System.Int64 - Parameter sets:
Id,InputObject
-S3Bucket
S3 bucket name
- Type:
System.String - Parameter sets:
Id,InputObject
-S3CompatibleAccessKey
S3-compatible: Access Key
- Type:
System.String - Parameter sets:
Id,InputObject
-S3CompatibleBucket
S3-compatible: Bucket name
- Type:
System.String - Parameter sets:
Id,InputObject
-S3CompatibleEndpoint
S3-compatible: endpoint
- Type:
System.String - Parameter sets:
Id,InputObject
-S3CompatibleRegion
S3-compatible: region
- Type:
System.String - Parameter sets:
Id,InputObject
-S3CompatibleVirtualHostedStyle
S3-compatible: If true, use virtual-hosted-style URLs instead of path-style URLs
- Type:
System.Boolean - Parameter sets:
Id,InputObject
-S3KmsKeyId
ARN of the AWS KMS key that encrypts files written to the bucket (SSE-KMS). Leave blank unless your bucket requires a specific key.
- Type:
System.String - Parameter sets:
Id,InputObject
-S3Region
S3 region
- Type:
System.String - Parameter sets:
Id,InputObject
-ServerCertificate
Remote server certificate
- Type:
System.String - Parameter sets:
Id,InputObject
-ServerHostKey
Pinned SSH host key or OpenSSH host certificate for SFTP. If omitted, Files.com detects and stores a host key, preferring plain keys over certificates. With server_certificate=require_match (the default), the server must present the exact pinned key or certificate and prove it holds the matching private key. A pinned certificate is compared in full, so renewal can require updating server_host_key even when its underlying key is unchanged. Files.com does not check certificate CA signatures, principals, or validity periods. Certificate expiration alone does not end the pin. Update server_host_key to replace the pin.
- Type:
System.String - Parameter sets:
Id,InputObject
-ServerType
Remote server type.
- Type:
System.String - Parameter sets:
Id,InputObject
-SharepointClientId
SharePoint: Microsoft Entra application client ID for app-only authentication.
- Type:
System.String - Parameter sets:
Id,InputObject
-SharepointSiteUrl
SharePoint: Site URL to scope app-only authentication to a single site. Leave blank to browse all sites.
- Type:
System.String - Parameter sets:
Id,InputObject
-SharepointTenantId
SharePoint: Microsoft Entra tenant ID for app-only authentication.
- Type:
System.String - Parameter sets:
Id,InputObject
-Ssl
Should we require SSL?
- Type:
System.String - Parameter sets:
Id,InputObject
-Username
Remote server username.
- Type:
System.String - Parameter sets:
Id,InputObject
-WasabiAccessKey
Wasabi: Access Key.
- Type:
System.String - Parameter sets:
Id,InputObject
-WasabiBucket
Wasabi: Bucket name
- Type:
System.String - Parameter sets:
Id,InputObject
-WasabiRegion
Wasabi: Region
- Type:
System.String - Parameter sets:
Id,InputObject
-InputObject
The remote server to act on, such as one written by another command of the module, from the pipeline. The command uses its Id and the connection that fetched it.
- Type:
FilesCom.PowerShell.Models.RemoteServer - Parameter sets:
InputObject(required)
-Connection
The connection to use, from Connect-FilesAccount. Defaults to the connection of the -InputObject or -Continuation given, and otherwise to the current runspace's default connection.
- Type:
FilesCom.PowerShell.FilesConnection - Parameter sets:
(All)
-WorkspaceScope
Runs this command's requests in this workspace, including workspace 0, instead of the connection's or, for an -InputObject, instead of the workspace the object was read in. The connection and the object are unchanged.
- Type:
System.Int64 - Parameter sets:
(All)
-NoWorkspaceScope
Runs this command's requests in no workspace, even if the connection has one. The connection itself is unchanged.
- Type:
System.Management.Automation.SwitchParameter - Parameter sets:
(All)
-Confirm
Prompts you for confirmation before running the cmdlet.
- Type:
System.Management.Automation.SwitchParameter - Confirm impact: High. At the default
$ConfirmPreferenceofHigh, the command asks before each change;-Confirm:$falseruns it without asking.
-WhatIf
Shows what the cmdlet would change without sending anything to Files.com.
- Type:
System.Management.Automation.SwitchParameter
Common Parameters
This cmdlet supports the PowerShell common parameters, such as -Verbose and -ErrorAction.
Inputs
FilesCom.PowerShell.Models.RemoteServer: a remote server from another command of the module, as-InputObject.
Outputs
FilesCom.PowerShell.Models.RemoteServer: the remote server as Files.com returned it.
Notes
Failures are written as error records with IDs such as Files.NotFound or Files.Authentication. Run Get-Help about_FilesCom for connections, paging, errors and previewing changes.