{"id":16480858,"url":"https://github.com/ramblingcookiemonster/psdeploy","last_synced_at":"2025-04-05T22:10:52.018Z","repository":{"id":36035586,"uuid":"40332329","full_name":"RamblingCookieMonster/PSDeploy","owner":"RamblingCookieMonster","description":"Simple PowerShell based deployments","archived":false,"fork":false,"pushed_at":"2021-01-13T22:00:55.000Z","size":1331,"stargazers_count":347,"open_issues_count":23,"forks_count":69,"subscribers_count":24,"default_branch":"master","last_synced_at":"2025-03-29T21:09:01.704Z","etag":null,"topics":["build","build-automation","build-pipelines","ci-cd","continuous-delivery","continuous-deployment","powershell","powershell-modules"],"latest_commit_sha":null,"homepage":"http://ramblingcookiemonster.github.io/PSDeploy-Take-Two/","language":"PowerShell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RamblingCookieMonster.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"Contributing.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":["ramblingcookiemonster"]}},"created_at":"2015-08-07T00:02:52.000Z","updated_at":"2025-01-04T17:40:14.000Z","dependencies_parsed_at":"2022-08-26T03:40:14.154Z","dependency_job_id":null,"html_url":"https://github.com/RamblingCookieMonster/PSDeploy","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RamblingCookieMonster%2FPSDeploy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RamblingCookieMonster%2FPSDeploy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RamblingCookieMonster%2FPSDeploy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RamblingCookieMonster%2FPSDeploy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RamblingCookieMonster","download_url":"https://codeload.github.com/RamblingCookieMonster/PSDeploy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247406111,"owners_count":20933806,"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":["build","build-automation","build-pipelines","ci-cd","continuous-delivery","continuous-deployment","powershell","powershell-modules"],"created_at":"2024-10-11T13:05:36.043Z","updated_at":"2025-04-05T22:10:51.995Z","avatar_url":"https://github.com/RamblingCookieMonster.png","language":"PowerShell","funding_links":["https://github.com/sponsors/ramblingcookiemonster"],"categories":[],"sub_categories":[],"readme":"[![Build status](https://ci.appveyor.com/api/projects/status/ntgl2679yn4g4m2b/branch/master?svg=true)](https://ci.appveyor.com/project/RamblingCookieMonster/psdeploy/branch/master) [![Documentation Status](https://readthedocs.org/projects/psdeploy/badge/?version=latest)](http://psdeploy.readthedocs.org/en/latest/?badge=latest)\n\nPSDeploy\n========\n\nPSDeploy is a quick and dirty module to simplify PowerShell based deployments.\n\nThe idea is that you write a *.psdeploy.ps1 deployment configuration with sources and targets, and PSDeploy will deploy these.\n\nSuggestions, pull requests, and other contributions would be more than welcome! See the [contributing guidlines](Contributing.md) for more info.\n\n## Deployments\n\nInvoking PSDeploy is very similar to running Invoke-Pester.  Here's an example, Some.PSDeploy.ps1\n\n```powershell\nDeploy ActiveDirectory1 {                        # Deployment name. This needs to be unique. Call it whatever you want\n    By Filesystem {                              # Deployment type. See Get-PSDeploymentType\n        FromSource 'Tasks\\AD\\Some-ADScript.ps1', # One or more sources to deploy. Absolute, or relative to deployment.yml parent\n                   'Tasks\\AllOfThisDirectory'\n        To '\\\\contoso.org\\share$\\Tasks'          # One or more destinations to deploy the sources to\n        Tagged Prod                              # One or more tags you can use to restrict deployments or queries\n        WithOptions @{\n            Mirror = $True                       # If the source is a folder, triggers robocopy purge. Danger\n        }\n    }\n}\n```\n\nLet's pretend Some.PSDeploy.ps1 lives in C:\\Git\\Misc\\Deployments. Here's what happens when we invoke a deployment:\n\n```powershell\nInvoke-PSDeploy -Path C:\\Git\\Misc\n```\n\n * We search for all *.*Deploy.ps1 or *PSDeploy.ps1 files under C:\\Git\\Misc, and find Some.PSDeploy.ps1. In this case, we have two resulting deployments, Some-ADScript.ps1, and AllOfThisDirectory\n * We check the deployment type. Filesystem.\n * We invoke the script associated with Filesystem Deployments, passing in the two deployments\n * Relative paths are resolved by joining paths with C:\\Git\\Misc\n * C:\\Git\\Misc\\Tasks\\AD\\Some-ADScript.ps1 is copied to \\\\contoso.org\\share$\\Tasks with Copy-Item\n * C:\\Git\\Misc\\Tasks\\AD\\Tasks\\AllOfThisDirectory is copied to \\\\contoso.org\\share$\\Tasks with robocopy, using /XO /E /PURGE (we only purge if mirror is true)\n\n## Initial PSDeploy setup\n\n```powershell\n# One time setup\n    # Download the repository\n    # Unblock the zip\n    # Extract the PSDeploy folder to a module path (e.g. $env:USERPROFILE\\Documents\\WindowsPowerShell\\Modules\\)\n\n    #Simple alternative, if you have PowerShell 5, or the PowerShellGet module:\n        Install-Module PSDeploy\n\n# Import the module.\n    Import-Module PSDeploy    # Alternatively, Import-Module \\\\Path\\To\\PSDeploy\n\n# Get commands in the module\n    Get-Command -Module PSDeploy\n\n# Get help for the module and a command\n    Get-Help about_PSDeploy\n    Get-Help Invoke-PSDeploy -full\n```\n\n## More Information\n\nThe [PSDeploy docs](http://psdeploy.readthedocs.org/) will include more information, including:\n\n* Examples for different DeploymentTypes - will try to keep these in sync with new types when they are added\n* Illustrations of features like tags and dependencies\n* Common scenarios (todo)\n* How to write new PSDeploy DeploymentTypes\n* Details on the PSDeploy Configuration Files\n\nThe blog posts ([one](http://ramblingcookiemonster.github.io/PSDeploy/), [two](http://ramblingcookiemonster.github.io/PSDeploy-Take-Two/)), and [three](http://ramblingcookiemonster.github.io/PSDeploy-Inception/) will become out of date over time, but may include helpful details\n\n## Notes\n\nThanks go to:\n\n* Scott Muc for [PowerYaml](https://github.com/scottmuc/PowerYaml), which we borrow for YAML parsing\n* Boe Prox for [Get-FileHash](http://learn-powershell.net/2013/03/25/use-powershell-to-calculate-the-hash-of-a-file/), which we borrow for downlevel hash support in the deployment scripts\n* Michael Greene, for the idea of using a DSL similar to Pester\n* Folks writing new PSDeploy deployment types and contributing in other ways - thank you!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Framblingcookiemonster%2Fpsdeploy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Framblingcookiemonster%2Fpsdeploy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Framblingcookiemonster%2Fpsdeploy/lists"}