Skip to content

Instantly share code, notes, and snippets.

View jiimaho's full-sized avatar
🎯
Focusing

Jim Aho jiimaho

🎯
Focusing
View GitHub Profile
@jiimaho
jiimaho / SlackNotificationOctopusDeploy.ps1
Last active January 17, 2019 11:06
Octopus script template for slack notifiation with release notes and deployment link
function Slack-Rich-Notification ($notification)
{
$payload = @{
channel = $OctopusParameters['Channel']
username = $OctopusParameters['Username'];
icon_url = $OctopusParameters['IconUrl'];
attachments = @(
@{
fallback = $notification["fallback"];
color = $notification["color"];
@jiimaho
jiimaho / gist:3aa25944b576edab097ce9bdf223729e
Last active March 15, 2017 07:58
SQL Server restore database from network drive to external disk
-- allow changes to advanced options
EXEC sp_configure 'show advanced options', 1
GO
-- Update currently configured values for advanced options.
RECONFIGURE
GO
-- To enable xp_cmdshell
EXEC sp_configure 'xp_cmdshell', 1
GO
-- Update currently configured values for advanced options.