Giter VIP home page Giter VIP logo

two-step-migrate's Introduction

two-step-migrate

SQL migration tool.

screenshot

This is tool is adapted for seamless deployments of backend code. Each migration has two steps: half and total.

Half migration is backward-compatible database migration, which allows to work previous and next version of your backend code simultaneously. In this migration you cannot remove or rename columns because in that case the old backend code will break.

Total migration is backward-not-compatible database migration.


Installation

Using precompiled binaries

The compiled binaries exist under the releases tab: https://github.com/reo7sp/two-step-migrate/releases

Using docker

Use reo7sp/two-step-migrate docker image.

Using go

go get github.com/reo7sp/two-step-migrate

Usage

two-step-migrate [command]

Available commands:

  • new — Create a new migration
  • up — Apply migration
  • down — Rollback migration

Required environment variables:

  • DATABASE_URL — DSN to the sql database.

Caveats

Currently supports only PostgreSQL.

two-step-migrate's People

Contributors

reo7sp avatar

Stargazers

 avatar  avatar

Watchers

 avatar  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.