POC DynamoDB to MySQL data migration

  1. Set AWS credentials on DynamoDBtoCSV/dynamoDBtoCSV.js

  2. Do the data dump from DynamoDB

        $ node DynamoDBtoCSV/dynamoDBtoCSV.js -t homolog-chubaca-carriers > dynamo_output/output.csv
  3. Start Docker services

    $ docker-compose up
  4. Enter the container and access database

    $ docker-compose exec mysql bash
    $ mysql -u root -p
  5. Create table schema

    CREATE TABLE carrier ...
  6. Run importation command

    LOAD DATA INFILE '/home/dynamo-output/output.csv'
    INTO TABLE table_name
    FIELDS TERMINATED BY ','
    ENCLOSED BY '"'
    LINES TERMINATED BY '/n'
    IGNORE 1 ROWS;