This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# UPDATE ME!!!! | |
$rgCloneEndpoint = "https://update-me:8132/" | |
# DON'T CHANGE ANYTHING ELSE | |
############################################################### | |
<# | |
For more information, see: | |
https://documentation.red-gate.com/redgate-clone/using-the-cli/cli-installation | |
#> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$testMode = $true # By default, don't actually delete anything. Just print out the commands you would execute without executing them. Set this to false if you want to actually delete stuff | |
$images = (rgclone get di --output json) | ConvertFrom-Json | |
$failedImageIds = ($images | Where-Object {$_.status -like "Failed"}).Id | |
$containers = (rgclone get dc --output json) | ConvertFrom-Json | |
$failedContainerIds = ($containers | Where-Object {$_.status -like "Failed"}).Id | |
if ($failedImageIds.length -ne 0){ | |
$failedImageIds | ForEach-Object { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sourceType: Backup | |
name: pagila-pg | |
engine: postgresql | |
version: 14 | |
backups: | |
- file: pagila-pg/dump-pagila_dev.sql | |
- file: pagila-pg/dump-pagila_shadow.sql | |
initialDatabaseName: pagila | |
postScript: | | |
CREATE ROLE redgate WITH LOGIN SUPERUSER PASSWORD 'not_the_real_password'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:: DO NOT BLINDLY RUN THIS FILE!!!! | |
:: It won't work. | |
:: Also, it's important you understand what each bit does. | |
:: Instead, step through it, one line at a time, reading the comments (::) as you go. | |
:: | |
:: STEP 0 - Download the rgclone command line | |
:: It's available here. (NOTE: You need to provide your own rgclone URL and port!): | |
:: https://rgclone-url.com:port/cloning-api/download/cli/windows-amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SET ANSI_NULLS ON | |
GO | |
SET QUOTED_IDENTIFIER ON | |
GO | |
-- If you want to use a different name for the table, update this variable | |
DECLARE @TABLENAME AS NVARCHAR(100)=N'flyway_schema_history'; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Set-SqlDefaultPath { | |
param ( | |
[Parameter(Mandatory=$true)][string]$SqlInstance, | |
$NewDefaultDataPath = "", | |
$NewDefaultLogPath = "", | |
$NewDefaultBackupPath = "" | |
) | |
try { | |
import-module dbatools | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Session type: | |
Lightning Talk | |
Title: | |
Dante's 9 Levels of Database Deployment Hell | |
Abstract: | |
Got a monolithic database with a zillion wicked dependencies? | |
Do database deployments send fear down your spine? | |
Have a dark sense of adventure? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Attribution to Ivan Donev | |
-- Details: | |
-- http://www.mssqlinsider.com/2013/09/check-databases-part-replication/ | |
-- Requires SA | |
IF IS_SRVROLEMEMBER ('sysadmin') = 1 | |
print 'Current user''s login is a member of the sysadmin role' | |
ELSE IF IS_SRVROLEMEMBER ('sysadmin') = 0 | |
THROW 50001, 'ERROR: Current user''s login is NOT a member of the sysadmin role.', 1 | |
ELSE IF IS_SRVROLEMEMBER ('sysadmin') IS NULL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
Queries the Octopus Deploy API to determine the state of a specific RunbookRun. | |
Possible states include: | |
- Queued | |
- Executing | |
- Success | |
- Failed | |
- TimedOut | |
- Cancelling |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Title: | |
tSQLt explained, by the maintainer | |
Abstract: | |
Back when you released quarterly, you might have got away with week-long manual testing cycles. However, DevOps has highlighted the risk associated with long lead times and large, complex deployments. Most of us understand the need to move much faster. | |
Unfortunately, continuous delivery, without continuous testing, is simply a more efficient way to deliver new bugs to production. It's all very well being able to deploy 10 times a day, but if you can't test 10 times a day, you are entering a Russian Roulette tournament without an exit strategy. It's no surprise that "DevOps Transformations" that skip the testing tend to fail. | |
We'll start with a bit of theory. What types of tests should you be writing? How many tests should you be writing? When should you be running the tests? How should you approach legacy databases? How is the role of the tester evolving? |
NewerOlder