Import a MySQL Database

This example assumes that there is a mysqldump file available somewhere via SSH. First import the Tugboat Repository's SSH key to the server hosting the file. Then use this configuration to import the database into a service named "mysql".

services:
  mysql:
    image: tugboatqa/mysql
    commands:
      init:
        - scp example.com/database.sql.gz /tmp/
        - zcat /tmp/database.sql.gz | mysql tugboat
        - rm /tmp/database.sql.gz

results matching ""

    No results matching ""