Code Monkey home page Code Monkey logo

applicationdatabasecreationscripts's Introduction

ApplicationDatabases

Do your application database creation and destruction reproducibly. Include application logins in that.

New-PostgresApplicationDatabase.ps1
Set-PostgresTemplate1DefaultLocale.ps1
New-SqlServerApplicationDatabase.ps1

New-PostgresApplicationDatabase.ps1

SYNOPSIS: Create a Postgres application database and roles for owner, application, and application_readonly   
    
SYNTAX
    New-PostgresApplicationDatabase.ps1 [[-databaseName] <String>] 
    [[-postgresHost] <String>] [[-adminUser] <String>] [[-databaseOwner] <String>] [[-appAccount] <String>] 
    [[-appAccountPassword] <String>] [[-readonlyAppAccount] <String>] [[-readonlyAppAccountPassword] <String>] 
    [[-template] <String>] [-template0] [[-encoding] <String>] [[-locale] <String>] [[-addUUID] <Boolean>] 
    [-addFunctionsForPSAndDropConnections] [-addPlv8] [-addTrigram] [-dryRun] [-help] [-helpAvailableLocales] 
    [-deleteDatabaseAndRoles] [<CommonParameters>]  
    
DESCRIPTION
    Create a Postgres application database and create roles for owner, application, and application_readonly.
    
    - the owner role has no login. the user that runs this script will be assigned to that role
    - the application and application_readonly roles will be login roles with password either specified by you
      or generated by this script. 
    - If the passwords are generated by this script, they will be printed as the first 
      2 lines of output of this script. 
    - If the script scram_postgres_password.py exists in the path, the passwords will be scram encrypted.
    
    - Optionally install common extensions UUID, plv8 and trigram
    - Optionally create functions for view and drop database connections

Set-PostgresTemplate1DefaultLocale.ps1

SYNOPSIS : Update Postgres template1 (which is the default template used by Create Database) to your preferred Locale settings.
    
SYNTAX
    Set-PostgresTemplate1DefaultLocale.ps1 [[-dbLocale] <Object>] 
    [[-postgresHost] <Object>] [[-adminUser] <String>] [[-dbEncoding] <Object>] [-createViewAndDropConnectionFunctions] 
    [-addPlv8] [-addTrigram] [-addUUID] [-dryRun] [<CommonParameters>]

New-SqlServerApplicationDatabase.ps1 [WIP, not finished]

SYNOPSIS
    Create an MS SQL Server application database and roles for application and application_readonly,
    and alter authorization to an applicationdatabaseowner account


SYNTAX
    New-SqlServerApplicationDatabase.ps1 [-databaseName <String>]
        [-serverInstance <String>]
        [-ciLogin <String>] [-ciLoginPassword <String>]
        [-appLogin <String>] [-appLoginIsDbOwner] [-appLoginPassword <String>]
        [-appReadonlyLogin <String>] [-appReadonlyLoginPassword <String>]
        [-dryRun] [-help] [-helpFull]
        [-databaseOwner <String>] [-deleteDatabaseAndLogins] [<CommonParameters>]

    New-SqlServerApplicationDatabase.ps1
        [-bootstrap] [-uninstallBootstrap]
        [-serverInstance <String>]
        [-saLogin <String>] [-saLoginPassword <String>]
        [-ciLogin <String>] [-ciLoginPassword <String>]
        [-dryRun] [-help] [-helpFull]
        [<CommonParameters>]


BOOTSTRAPPING

    Run this script first with the -bootstrap parameter and an sa login to create the assets needed
    to use the script on SQL Server.

DESCRIPTION
    Create an MS SQL Server application database and roles for application and application_readonly,
    and alter authorization to an applicationdatabaseowner account.

    - the application and application_readonly roles will be login roles with password either
      specified by you or generated by this script.
    - If the passwords are generated by this script, they will be printed as the first 2 lines
      of output of this script.



applicationdatabasecreationscripts's People

Contributors

chrisfcarroll avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.