{"id":22549868,"url":"https://github.com/heusalagroup/hg-dashboard","last_synced_at":"2026-04-11T12:42:46.869Z","repository":{"id":143791133,"uuid":"522854941","full_name":"heusalagroup/hg-dashboard","owner":"heusalagroup","description":"HG Dashboard Sample Project","archived":false,"fork":false,"pushed_at":"2023-03-02T13:24:52.000Z","size":2409,"stargazers_count":0,"open_issues_count":6,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-06-05T12:05:31.212Z","etag":null,"topics":["backend","dashboard-application","development-environment-setup","docker","docker-compose","email","frontend","fullstack","login-system","matrix-org","reactjs","rest-api","sample-project","spring-boot","template","testing","typescript","user-management-system"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/heusalagroup.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-08-09T07:55:36.000Z","updated_at":"2022-10-26T20:49:16.000Z","dependencies_parsed_at":null,"dependency_job_id":"66113281-57e0-48b2-b18f-4d5241c62abe","html_url":"https://github.com/heusalagroup/hg-dashboard","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/heusalagroup/hg-dashboard","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heusalagroup%2Fhg-dashboard","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heusalagroup%2Fhg-dashboard/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heusalagroup%2Fhg-dashboard/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heusalagroup%2Fhg-dashboard/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/heusalagroup","download_url":"https://codeload.github.com/heusalagroup/hg-dashboard/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heusalagroup%2Fhg-dashboard/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266644950,"owners_count":23961614,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-23T02:00:09.312Z","response_time":66,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["backend","dashboard-application","development-environment-setup","docker","docker-compose","email","frontend","fullstack","login-system","matrix-org","reactjs","rest-api","sample-project","spring-boot","template","testing","typescript","user-management-system"],"created_at":"2024-12-07T16:10:10.331Z","updated_at":"2025-10-20T00:47:29.894Z","avatar_url":"https://github.com/heusalagroup.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @heusalagroup/hg-dashboard\n\nHG's Dashboard Project to bootstrap full stack TypeScript projects.\n\n## Working on the local development environment\n\n### Fetching source code\n\n```shell\ngit clone git@github.com:heusalagroup/hg-dashboard.git hg-dashboard\ncd hg-dashboard\ngit submodule update --init --recursive\n```\n\n### Building local environment\n\n```shell\ndocker-compose build\n```\n\n### Local environment using non-persistent memory repository \n\nThe memory based repository saves everything to non-persistent local memory. \n\nIt's faster, but doesn't persist any state between runs. It also doesn't need \nany initialization tasks.\n\n```shell\ndocker-compose -f ./docker-compose.memory.yml build\ndocker-compose -f ./docker-compose.memory.yml up\n```\n\nHowever, it's useful only for development.\n\n### Local environment with Synapse server\n\nOur default environment uses Synapse Matrix server to store persistent data to\nPostgreSQL database.\n\nSynapse is the official Matrix server. It's written using Python programming language.\n\n#### Initializing Synapse server\n\nYou'll need to create an account for the application on the Synapse server before \nstarting up everything.\n\nFirst start up only your Matrix server:\n\n```shell\ndocker-compose up -d hg-dashboard-io\n```\n\nThis needs to be run only once -- and if you clean up your `./io/data/homeserver.db`:\n\n```shell\ndocker exec -it hg-dashboard-io register_new_matrix_user http://localhost:8008 -c /data/homeserver.yaml --no-admin -u app -p p4sSw0rd123\n```\n\nOnce added, you can stop the Matrix server:\n\n```shell\ndocker-compose down -d hg-dashboard-io\n```\n\n#### Starting environment (with Synapse Matrix server)\n\n```shell\ndocker-compose up\n```\n\n### Local environment with Dendrite Matrix server\n\nDendrite is another implementation for Matrix. It's written using Go programming\nlanguage.\n\n#### Initializing Dendrite Matrix server\n\nYou'll need to create an account for the application on the Dendrite server before\nstarting up everything.\n\nFirst start up only your Matrix server:\n\n```shell\ndocker-compose -f ./docker-compose.dendrite.yml up -d hg-dashboard-io-dendrite\n```\n\nThen create the account for the app:\n\n```shell\ndocker exec -it hg-dashboard-io-dendrite /usr/bin/create-account -config /etc/dendrite/dendrite.yaml -username app -password p4sSw0rd123\n```\n\nOnce added, you can stop the Matrix server:\n\n```shell\ndocker-compose -f ./docker-compose.dendrite.yml down -d hg-dashboard-io-dendrite\n```\n\n#### Starting environment (with Dendrite Matrix server)\n\n```shell\ndocker-compose -f ./docker-compose.dendrite.yml up\n```\n\n### Using the development environment\n\n#### Available Docker services\n\nOnce services are running, following services are available:\n\n* http://localhost:8080     -- The dashboard app in production mode (e.g. through Nginx HTTP server)\n* http://localhost:8080/api -- The dashboard backend through Nginx HTTP server\n* http://localhost:3500     -- Dashboard Backend Server (direct access)\n* http://localhost:8025     -- Web UI for SMTP Server for development purposes (MailHog)\n* http://localhost:8008     -- Matrix.org IO Server (Synapse or Dendrite)\n* `smtp://localhost:1025`   -- SMTP server (MailHog)\n\n#### Development frontend\n\nOnce you run `npm start` inside the frontend directory, the app will be available at:\n\n* http://localhost:3000     -- The dashboard frontend in development mode\n* http://localhost:3000/api -- The dashboard backend redirected to local port 3500\n\n#### Logging in to the dashboard\n\nBy default, only users using email addresses from accepted domains can log in and \ncreate initial workspaces.\n\nYou don't need to have access to the email address to use the development system.\nAny email message the local system sends can be read from the MailHog interface \nat [localhost:8025](http://localhost:8025). The verification code is also printed \non the server's debug log.\n\nYou can change this domain by changing `VALID_ADMIN_DOMAINS` array at \n`backend/src//fi/hg/dashboard/constants/dashboard-api.ts`. It defaults to the \ndomain `example.fi` and `example.com`. You need to build the system again to make\nthe change work.\n\nOnce a user with another email address is added to a workspace they can log in \nto the system -- even if not using example domains.\n\n### Update all git submodules\n\nWe have a script to update all changes from upstream git repositories.\n\n```shell\n./scripts/pull-all.sh\n```\n\nIt will read `.gitmodules` and use it to fetch all submodules using `git pull` \ninside submodule folders. It will pull also the main git repository.\n\n### Running tests\n\nFor testing, you need to have full docker environment running. \n\nThen open another terminal and go to the testing folder:\n\n```shell\ncd testing\n```\n\n#### Install testing environment\n\n```shell\nnpm install\n```\n\n#### Running tests\n\n```shell\nnpm test\n```\n\n## Working on the GitHub\n\nAdvices about working on GitHub environment.\n\n### Find and set project on unlisted issues\n\nOur issue templates do not set the project automatically. Because of that, it's\ncommon that some issues are left unlisted on the board.\n\nYou can find unlisted issues with a search label `-project:PROJECT` where the `PROJECT` is `heusalagroup/1` for example.\n\n 1. Go to [the Issues page](https://github.com/heusalagroup/hg-dashboard/issues?q=is%3Aissue+is%3Aopen+-project%3Aheusalagroup%2F1) (e.g. with `-project:heusalagroup/1`, any issue not in the MVP project)\n 2. Select all found issues\n 3. Set project as `MVP`\n\n### Find and set unlabeled issues\n\nSometimes some issues are created without any labels.\n\n1. Go to [the Issues page](https://github.com/heusalagroup/hg-dashboard/issues?q=is%3Aissue+is%3Aopen+no%3Alabel) (e.g. with `no:label`, any issue without label)\n2. Select issues of specific type (e.g. `[Task]` in the title means tasks)\n3. Set label to those types (e.g. `task` for tasks)\n\n### Starting production environment\n\nThis is the easiest way to run the full environment.\n\n```shell\nDOCKER_HOST_IP=172.16.50.54 \\\nBACKEND_JWT_SECRET='secret-code' \\\nBACKEND_IO_SERVER='https://user:secret@io.hg.fi' \\\nBACKEND_EMAIL_CONFIG='smtp://host.docker.internal:25'\ndocker-compose -f docker-compose.prod.yml up -d\n```\n\n### Troubleshooting\n\n#### Connection aborted / Failed to execute script docker-compose\n\n```\ndocker.errors.DockerException: Error while fetching server API version: ('Connection aborted.', FileNotFoundError(2, 'No such file or directory'))\n[8089] Failed to execute script docker-compose\n```\n\nYou'll need to start up Docker Engine first :)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheusalagroup%2Fhg-dashboard","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fheusalagroup%2Fhg-dashboard","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheusalagroup%2Fhg-dashboard/lists"}