Skip to content

A simple, open-source and self-hosted habit tracker app.

License

Notifications You must be signed in to change notification settings

FR0ST1N/MyDailies

Repository files navigation

MyDailies

A simple, open-source and self-hosted habit tracker app.

Banner

Click here for screenshots.

Features

  • Simple UI 👌
  • Dark mode 🌕
  • Easy deployment with Docker. 🐋

Deployment

Make sure you have Docker and Docker Compose installed.

  1. Clone the repo.
git clone https://github.com/FR0ST1N/MyDailies.git
  1. Go to project root.
cd MyDailies
  1. Set JWT_SECRET_KEY environment variable in the api Dockerfile.
  2. Run docker compose.
docker compose up
  1. Create the first user (this user will be an admin and can add more users from the users page accessed from the menu).
curl -X POST http://localhost:8080/api/user/setup-admin \
-H 'Content-Type: application/json' \
-d '{"email": "[email protected]", "password": "password", "name": "Your Name", "timezone": "TZ database name"}'

List of tz database time zones

Development

Start server

API Server

Make sure you have air installed. If not, install it from here.

  • Start API server with air

Web Server

CD into the web directory and run the following commands.

  • Install dependencies npm ci
  • Start the server npm start

Run tests

  • API unit test can be run using go test ./...

Code Formatting

  • API gofmt -w -s .
  • Web npm run format

License