Giter VIP home page Giter VIP logo

docker-postgres-pitr's Introduction

docker-postgres-pitr-lab

docker run --name pgtest -p 15432:5432 -v /etc/localtime:/etc/localtime:ro -v /home/magnus.persson/pitrlabb/pitr-archive/$(date +%Y%m%d-%H%M%S)/archive:/var/lib/postgresql/archive -d postgres ./postconfigure-pitr.sh pgtest pg_basebackup -D pitr-archive/20140715-132644/basebackup -h 127.0.0.1 -p 15432 -U postgres docker run -i -t --rm --link pgtest:db --name foo -v /etc/localtime:/etc/localtime:ro -e PGRUNS=15 magnusp/runner

docker run --name pgrestore -p 15433:5432 -v /etc/localtime:/etc/localtime:ro -v /home/magnus.persson/pitrlabb/pitr-archive/20140714-150853/archive:/var/lib/postgresql/restore-archive:ro -v /home/magnus.persson/pitrlabb/pitr-archive/20140714-150853/basebackup:/var/lib/postgresql/basebackup:ro postgres sh -c "cp -R /var/lib/postgresql/basebackup/* /var/lib/postgresql/data && echo restore_command='/bin/cp /var/lib/postgresql/restore-archive/%f %p' >> /var/lib/postgresql/data/recovery.conf && echo archive_command='' >> /var/lib/postgresql/data/postgresql.conf && echo wal_level=minimal >> /var/lib/postgresql/data/postgresql.conf && echo archive_mode=off >> /var/lib/postgresql/data/postgresql.conf && echo max_wal_senders=0 >> /var/lib/postgresql/data/postgresql.conf && echo recovery_target_time='2014-07-14 15:25:04.007633' >> /var/lib/postgresql/data/recovery.conf && echo log_statement='all' >> /var/lib/postgresql/data/postgresql.conf && echo log_min_duration_statement=-1 >> /var/lib/postgresql/data/postgresql.conf && chown -R postgres:postgres /var/lib/postgresql/data && cat /var/lib/postgresql/data/postgresql.conf /var/lib/postgresql/data/recovery.conf && chmod 0700 /var/lib/postgresql/data && exec gosu postgres postgres -D /var/lib/postgresql/data"

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.