go run .\cmd\api\main.go
docker compose up
http://localhost:3457/crawl?url=https://en.wikipedia.org/wiki/Futures_and_promises
It'll save the pages data at the database.
You'll need golang-migrate installed:
go install -tags 'postgres' github.com/golang-migrate/migrate/v4/cmd/migrate@latest
Then you can execute the following command to create a migration:
migrate create -ext sql -dir cmd/migrate/migrations -seq my_migration_name
Execute:
go install -v github.com/go-delve/delve/cmd/dlv@latest
Then hit F5 at visual studio code.
docker build -t avicrawler
docker run --publish 3457:3457 --name avicrawler avicrawler