Skip to content

Latest commit

 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Docker DB Creation Commands:

  • docker run --name ecomm-mysql -p 3306:3306 -e MYSQL_ROOT_PASSWORD=password -d mysql
  • docker exec -i ecomm-mysql mysql -uroot -ppassword <<< "CREATE DATABASE ecomm;"
  • docker ps -a

Docker DB Mirgation Commands:

  • docker run -it --rm --network host --volume "$(pwd)/db:/db" migrate/migrate create -ext sql -dir /db/migrations init_schema
  • docker run -it --rm --network host --volume "$(pwd)/db:/db" migrate/migrate create -ext sql -dir /db/migrations add_users_table
  • docker run -it --rm --network host --volume ./db:/db migrate/migrate -path=/db/migrations -database "mysql://root:password@tcp(localhost:3306)/ecomm" up

Go Testing Commands:

  • cd path/to/test -> go test -v -cover

About

Ecommerce api project that makes use of golang, sqlx, mysql, http, grpc, docker and kubernetes

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages