{"id":21313971,"url":"https://github.com/octopusdeploy/octopusdsc","last_synced_at":"2025-04-04T08:06:49.225Z","repository":{"id":18357634,"uuid":"21537684","full_name":"OctopusDeploy/OctopusDSC","owner":"OctopusDeploy","description":"| Public |  A PowerShell DSC resource for installing Octopus Deploy \u0026 Tentacles","archived":false,"fork":false,"pushed_at":"2025-03-07T01:11:33.000Z","size":1077,"stargazers_count":1,"open_issues_count":23,"forks_count":60,"subscribers_count":10,"default_branch":"master","last_synced_at":"2025-03-28T07:06:21.535Z","etag":null,"topics":["public"],"latest_commit_sha":null,"homepage":"","language":"PowerShell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/OctopusDeploy.png","metadata":{"files":{"readme":"README-cOctopusServer.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2014-07-06T10:12:04.000Z","updated_at":"2025-01-05T22:55:05.000Z","dependencies_parsed_at":"2024-06-19T04:08:19.085Z","dependency_job_id":"0503e4be-b83d-4c94-a518-1881ffc2ac4e","html_url":"https://github.com/OctopusDeploy/OctopusDSC","commit_stats":{"total_commits":516,"total_committers":36,"mean_commits":"14.333333333333334","dds":0.5949612403100775,"last_synced_commit":"8855b53d9e916587246db1e01bf9edf1d087dd51"},"previous_names":[],"tags_count":173,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctopusDeploy%2FOctopusDSC","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctopusDeploy%2FOctopusDSC/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctopusDeploy%2FOctopusDSC/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctopusDeploy%2FOctopusDSC/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OctopusDeploy","download_url":"https://codeload.github.com/OctopusDeploy/OctopusDSC/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247142063,"owners_count":20890652,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["public"],"created_at":"2024-11-21T18:09:33.551Z","updated_at":"2025-04-04T08:06:49.206Z","avatar_url":"https://github.com/OctopusDeploy.png","language":"PowerShell","readme":"# cOctopusServer\n\n## Important note about usage statistics\n\nWe had previously made an inadvertent representation with regard to the collection of usage statistics. We had called the parameter `AllowCollectionOfAnonymousUsageStatistics`, when in fact it is possible for us to link this usage to your license key.\n\nIf this is enabled, we only collect aggregated feature usage statistics, such as number of projects, number of environments, number of machines etc. We never collect detailed information - things like names, descriptions, urls, variables etc are never collected. Please see [our docs](https://octopus.com/docs/administration/security/outbound-requests#Outboundrequests-WhatinformationisincludedwhenOctopuschecksforupdates) for full details on whats included.\n\nAs this was a change we wanted to bring to your attention, we have bumped the major version number (to represent a breaking change) and renamed the parameter to allow you the chance to change the setting.\n\nIf you wish to have your usage data deleted, please send us an email to \u003csupport@octopus.com\u003e with the serial number from your license key and we will delete it from our database.\n\nWe sincerely apologise for the mistake.\n\n## Sample\n\nFirst, ensure the OctopusDSC module is on your `$env:PSModulePath`. Then you can create and apply configuration like this.\n\n```PowerShell\nConfiguration SampleConfig\n{\n    Import-DscResource -Module OctopusDSC\n\n    Node \"localhost\"\n    {\n        cOctopusServer OctopusServer\n        {\n            Ensure = \"Present\"\n            State = \"Started\"\n\n            # Server instance name. Leave it as 'OctopusServer' unless you have more\n            # than one instance\n            Name = \"OctopusServer\"\n\n            # The url that Octopus will listen on\n            WebListenPrefix = \"http://localhost:81\"\n\n            SqlDbConnectionString = \"Server=(local)\\SQLEXPRESS;Database=Octopus;Trusted_Connection=True;\"\n\n            # The admin user to create\n            OctopusAdminCredential = $PSCredentialObject\n\n            # optional parameters\n            AllowUpgradeCheck = $true\n            AllowCollectionOfUsageStatistics = $true\n            ForceSSL = $false\n            ListenPort = 10943\n            DownloadUrl = \"https://octopus.com/downloads/latest/WindowsX64/OctopusServer\"\n            HSTSEnabled = $false\n            HSTSMaxAge = 3600 # 1hour\n\n            # for pre 3.5, valid values are \"UsernamePassword\"\n            # for 3.5 and above, only \"Ignore\" is valid (this is the default value)\n            LegacyWebAuthenticationMode = \"UsernamePassword\"\n\n            HomeDirectory = \"C:\\Octopus\"\n            TaskLogsDirectory = \"E:\\OctopusTaskLogs\" # defaults to \"$HomeDirectory\\TaskLogs\"\n            PackagesDirectory = \"E:\\OctopusPackages\" # defaults to \"$HomeDirectory\\Packages\"\n            ArtifactsDirectory = \"E:\\OctopusArtifacts\" # defaults to \"$HomeDirectory\\Artifacts\"\n\n            # if not supplied, Octopus will use a free license\n            LicenseKey = \"base64encodedlicense\"\n\n\n            TaskCap = 10\n        }\n    }\n}\n\nSampleConfig\n\nStart-DscConfiguration .\\SampleConfig -Verbose -wait\n\nTest-DscConfiguration\n```\n\n## Settings\n\nWhen `Ensure` is set to `Present`, the resource will:\n\n 1. Download the Octopus Server MSI from the internet\n 2. Install the MSI\n 3. Create the database\n 4. Set the admin username and password\n 5. Configure with a free licence\n 6. Start the service\n\nWhen `Ensure` is set to `Absent`, the resource will:\n\n 1. Delete the Octopus Server windows service\n 2. Uninstall using the MSI if there are no other instances installed on this machine\n\nWhen `State` is `Started`, the resource will ensure that the Octopus Servr windows service is running. When `Stopped`, it will ensure the service is stopped.\n\n## Properties\n\n| Property                              | Type                                                | Default Value                                                   | Description |\n| ------------------------------------- | --------------------------------------------------- | ----------------------------------------------------------------| ------------|\n| `Ensure`                              | `string` - `Present` or `Absent`                    | `Present`                                                       | The desired state of the Octopus Server - effectively whether to install or uninstall. |\n| `Name`                                | `string`                                            |                                                                 | The name of the Octopus Server instance. Use `OctopusServer` by convention unless you have more than one instance. |\n| `State`                               | `string` - `Started` or `Stopped`                   | `Started`                                                       | The desired state of the Octopus Server service. |\n| `DownloadUrl`                         | `string`                                            | `https://octopus.com/downloads/latest/WindowsX64/OctopusServer` | The url to use to download the msi. |\n| `SqlDbConnectionString`               | `string`                                            |                                                                 | The connection string to use to connect to the SQL Server database. |\n| `WebListenPrefix`                     | `string`                                            |                                                                 | A semi-colon (`;`) delimited list of urls on which the server should listen. eg `https://octopus.example.com:81`. |\n| `OctopusAdminCredential`              | `PSCredential`                                      | `[PSCredential]::Empty`                                         | The name/password of the administrative user to create on first install. |\n| `AllowUpgradeCheck`                   | `boolean`                                           | `$true`                                                         | Whether the server should check for updates periodically. |\n| `AllowCollectionOfUsageStatistics`    | `boolean`                                           | `$true`                                                         | Allow reporting of aggregated feature usage statistics during upgrade check, such as number of Tentacles/projects/environments etc. |\n| `LegacyWebAuthenticationMode`         | `string` - `UsernamePassword`, `Domain` or `Ignore` | `Ignore`                                                        | For Octopus version older than 3.5, allows you to configure how users login. For 3.5 and above, this must be set to `ignore`.  |\n| `ForceSSL`                            | `boolean`                                           | `$false`                                                        | Whether SSL should be required (HTTP requests get redirected to HTTPS) |\n| `ListenPort`                          | `int`                                               | `10943`                                                         | The port on which the Server should listen for communication from `Polling` Tentacles. |\n| `HSTSEnabled`                         | `boolean`                                           | `$false`                                                        | Whether Octopus should send the HSTS header |\n| `HSTSMaxAge`                          | `int`                                               | `3600`                                                          | The max age of the HSTS header |\n| `AutoLoginEnabled`                    | `boolean`                                           |                                                                 | If an authentication provider is enabled that supports pass through authentication (eg Active Directory), allow the user to automatically sign in. Only supported from Octopus 3.5. |\n| `OctopusServiceCredential`            | `PSCredential`                                      | `[PSCredential]::Empty`                                         | Credentials of the account used to run the Octopus Service |\n| `HomeDirectory`                       | `string`                                            | `C:\\Octopus`                                                    | Home directory for Octopus logs and config (where supported) |\n| `PackagesDirectory`                   | `string`                                            | `$HomeDirectory\\Packages`                                       | Directory where uploaded packages are stored. |\n| `ArtifactsDirectory`                  | `string`                                            | `$HomeDirectory\\Artifacts`                                      | Directory where deployment artifacts are stored |\n| `TaskLogsDirectory`                   | `string`                                            | `$HomeDirectory\\TaskLogs`                                       | Directory where deployment logs are stored |\n| `LicenseKey`                          | `string`                                            |                                                                 | The Base64 (UTF8) encoded license key. If not supplied, uses a free license. Drift detection is only supported from Octopus 4.1.3. |\n| `SkipLicenseCheck`                    | `boolen`                                            | `$false`                                                        | Force the license to be applied by skipping the license compliance check. Warning: if your installation is not compliant with your license, deployments and other activities may be blocked. |\n| `GrantDatabasePermissions`            | `boolean`                                           | `$true`                                                         | Whether to grant `db_owner` permissions to the service account user (`$OctopusServiceCredential` user if supplied, or `NT AUTHORITY\\System`)  |\n| `OctopusMasterKey`                    | `PSCredential`                                      | `[PSCredential]::Empty`                                         | The master key for the existing database. |\n| `OctopusBuiltInWorkerCredential`      | `PSCredential`                                      | `[PSCredential]::Empty`                                         | The user account to use to execute run-on-server scripts. If not supplied, executes scripts under the service account used for `Octopus.Server.exe` |\n| `LogTaskMetrics`                      | `boolean`                                           | `$false`                                                        | DEPRECATED. Whether to log task metrics |\n| `LogRequestMetrics`                   | `boolean`                                           | `$false`                                                        | DEPRECATED. Whether to log api requests metrics |\n| `TaskCap`                             | `int`                                               |                                                                 | The number of tasks this Octopus Server node should attempt to process at once |\n\n## Drift\n\nThe server will be automatically reconfigured if you change any properties above. If the `DownloadUrl` property changes, it will detect the configuration drift and upgrade the Server as appropriate. However, if you leave it as default (ie 'install latest'), it will not upgrade when a new version is released - it only actions on change of the property.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foctopusdeploy%2Foctopusdsc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foctopusdeploy%2Foctopusdsc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foctopusdeploy%2Foctopusdsc/lists"}