2021-03-23 06:07:39 +00:00
|
|
|
# go-scrobble
|
|
|
|
|
2021-03-27 21:39:08 +00:00
|
|
|
Golang based music scrobbler.
|
2021-03-23 08:43:44 +00:00
|
|
|
|
2021-03-27 21:39:08 +00:00
|
|
|
Stack: Go 1.16+, Node 15+, React 17+, MySQL 8.0+, Redis
|
2021-03-24 04:19:18 +00:00
|
|
|
|
2021-03-27 21:39:08 +00:00
|
|
|
There are prebuilt binaries/packages available.
|
2021-03-23 08:43:44 +00:00
|
|
|
|
2021-03-27 21:39:08 +00:00
|
|
|
Copy .env.example to .env and set variables. You can use https://www.grc.com/passwords.htm to generate a JWT_SECRET.
|
2021-03-23 08:43:44 +00:00
|
|
|
|
2021-03-27 21:57:23 +00:00
|
|
|
## More documentation
|
2021-03-28 08:52:34 +00:00
|
|
|
[Changelog](docs/changelog.md)
|
|
|
|
|
2021-03-27 21:57:23 +00:00
|
|
|
[Environment Variables](docs/config.md)
|
|
|
|
|
2021-03-24 09:28:05 +00:00
|
|
|
## Setup MySQL
|
2021-03-23 08:43:44 +00:00
|
|
|
create user 'goscrobble'@'%' identified by 'supersecurepass';
|
|
|
|
create database goscrobble;
|
|
|
|
grant all privileges on goscrobble.* to 'goscrobble'@'%';
|
|
|
|
|
2021-03-27 21:57:23 +00:00
|
|
|
## Local Development
|
2021-03-25 05:15:01 +00:00
|
|
|
cp .env.example .env # Fill in the blanks
|
2021-03-23 08:43:44 +00:00
|
|
|
go mod tidy
|
2021-03-25 05:15:01 +00:00
|
|
|
CGO_ENABLED=0 go run cmd/go-scrobble/*.go
|
2021-03-23 08:43:44 +00:00
|
|
|
|
|
|
|
|
2021-12-25 07:58:24 +00:00
|
|
|
Access API @ http://127.0.0.1:42069/api/v1
|
2021-03-24 03:29:35 +00:00
|
|
|
|
|
|
|
## Prod deployment
|
2021-03-25 05:15:01 +00:00
|
|
|
cp .env.example .env # Fill in the blanks
|
2021-03-24 03:29:35 +00:00
|
|
|
go build -o goscrobble cmd/go-scrobble/*.go
|
2021-03-27 21:39:08 +00:00
|
|
|
./goscrobble
|
|
|
|
|
2021-12-24 23:05:57 +00:00
|
|
|
## Build API Docs
|
|
|
|
cd docs/api && docker run --rm --name slate -v $(pwd)/build:/srv/slate/build -v $(pwd)/source:/srv/slate/source slatedocs/slate build
|
|
|
|
|
|
|
|
|
|
|
|
## Test API Docs
|
|
|
|
cd docs/api && docker run --rm --name slate -p 4567:4567 -v $(pwd)/source:/srv/slate/source slatedocs/slate serve
|
2021-03-27 21:39:08 +00:00
|
|
|
|
|
|
|
## Support Development!
|
|
|
|
Feel free to support hosting and my coffee addiction https://liberapay.com/idanoo
|