lorint / AdventureWorks-for-Postgres

Set up the AdventureWorks sample database for use with Postgres
MIT License
369 stars 185 forks source link

convert manual steps into a Makefile chain #18

Open dvdotsenko opened 8 months ago

dvdotsenko commented 8 months ago

Goals:

  1. Intentionally separate destination DB instance from all the Ruby-based conversion (and runtime) code. Intentionally separated psql runner from destination DB instance (now psql runs in a separate container and quits). This is to allow destination DB to be any instance of Postgres. Just feed credentials to this script and send data to destination Postgres instance.
  2. Use pure vendor images for everything: Ruby, Postgres. Makes things run faster (no image build step) and allows easy swap of versions of Ruby and Postgres runtimes.
  3. I tend to use this a lot now to bootstrap a demo server. Needed full automation and as few commands as possible. Also needed reentrant run (where if AdventureWorks.zip is already downloaded, script automatically just goes to next step. This allowed air-gapped use on internet-limited machines.