Skip to content

OpenHistoricalMap/ohm-db-migration

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

OpenHistoricalMap DB migration

This is a script for performing the database migration of the Web API using Helm, and basic configurations to carry out the migration

Requirements:

  • Access to AWS OHM account
  • Access to the staging and production clusters

Export environment values

export AWS_AVAILABILITY_ZONE=us-east-1a
export ENVIROMENT=staging
export EBS_DISK_SIZE=200
export POSTGRES_DB=db
export POSTGRES_PASSWORD=abc
export POSTGRES_USER=xyz
export PGUSER=xyz
export RESTORE_URL_FILE="https://osmseed-production-db.s3.us-east-1.amazonaws.com/database/db.sql.gz"

Creating the EBS disk

aws ec2 create-volume \
    --volume-type gp2 \
    --size $EBS_DISK_SIZE \
    --availability-zone $AWS_AVAILABILITY_ZONE \
    --tag-specifications \
    "ResourceType=volume,Tags=[{Key=Enviroment,Value=$ENVIROMENT},{Key=Name,Value=osmseed-$ENVIROMENT-api-web-db}]"

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages