Programming

Run a Console Application With PowerShell

Posted on

I have a DbUp console application that needed to be executed with PowerShell (in my case via Octopus Deploy – but this works in any case), but I wanted to be able to get the result when executing it. By default, running the “Database.exe” from PowerShell will open a new console window for the application […]

Programming

Poking Around Services Using Commands

Posted on

Important Note! These commands for Windows Services work if you run Command Prompt as Administrator. List All Services SC QUERY state=all > “C:\Temp\Services.txt” This will drop a text file (because you’re likely to have more information than your command buffer) into the temp folder for your perusal. Start / Stop a Service Start a service… […]

Automation

Reconfigure Octopus Deploy on a Cloned VM

Posted on

If you clone a VM that has an existing Octopus Deploy tentacle running, you’ll find that you’ll have a problem with a thumbprint clash. All you need to do is generate a new thumprint using tentacle.exe. You can do this using a command window, or PowerShell… cd “c:\Program Files\Octopus Deploy\Tentacle” .\tentacle.exe new-certificate This command will […]

Automation

Using PowerShell to Create Windows Users

Posted on

Due to replication needing a few Windows users scattered about the place, I needed to write a PowerShell script to create the users as part of the Octopus Deploy automated deployment. For completeness, I have added some users to this script, but you can use “Sensitive” variables in Octopus Deploy to hide away important information […]