Build with go build
To listen on port 3000:
goworldtime
To override the port:
goworldtime --port=4040
Edit test_data.json
and run the tester script to add new times:
./tester.sh
Or upload directly with curl:
curl -v -X POST \
-d '{"hours": 0, "minutes": 0, "seconds": 0, "day": 13, "month": 2, "year": 2020, "tz": "America/Los_Angeles"}' \
-H 'Content-Type: multipart/form-data' \
http://localhost:4040/times
Run a few times with different values and then fetch /times
to see the times:
http://localhost:4040/times