{"id":17652227,"url":"https://github.com/impworks/bonsai","last_synced_at":"2025-04-09T21:22:15.089Z","repository":{"id":45099676,"uuid":"105757842","full_name":"impworks/bonsai","owner":"impworks","description":"Self-hosted family wiki engine / photoalbum","archived":false,"fork":false,"pushed_at":"2024-04-13T18:16:02.000Z","size":3886,"stargazers_count":196,"open_issues_count":17,"forks_count":23,"subscribers_count":18,"default_branch":"master","last_synced_at":"2024-04-14T08:49:47.406Z","etag":null,"topics":["ancestry","calendar","family","family-tree","family-wiki","family-wiki-engine","pedigree","photo-album","photoalbum","photos","wiki"],"latest_commit_sha":null,"homepage":"","language":"C#","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/impworks.png","metadata":{"files":{"readme":"README.en.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}},"created_at":"2017-10-04T10:52:51.000Z","updated_at":"2024-04-17T21:29:15.265Z","dependencies_parsed_at":"2023-11-24T20:31:32.305Z","dependency_job_id":"b2ff16fe-f932-46b1-8d3a-0fdaa8cc9bea","html_url":"https://github.com/impworks/bonsai","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/impworks%2Fbonsai","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/impworks%2Fbonsai/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/impworks%2Fbonsai/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/impworks%2Fbonsai/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/impworks","download_url":"https://codeload.github.com/impworks/bonsai/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248112706,"owners_count":21049703,"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","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":["ancestry","calendar","family","family-tree","family-wiki","family-wiki-engine","pedigree","photo-album","photoalbum","photos","wiki"],"created_at":"2024-10-23T11:46:14.906Z","updated_at":"2025-04-09T21:22:15.074Z","avatar_url":"https://github.com/impworks.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bonsai\n\nA family wiki and photoalbum engine.\n\n### [Live demo](https://bonsai.kirillorlov.pro)\n\n## Features\n\n* Pages with Markdown text\n* Media files: photos, videos (PDF documents will be supported later)\n* Person tags on photos\n* Relations: validation, inferrence\n* Fact storage (birthday, gender, blood type, languages, hobbies, etc.)\n* Access control: editor, reader and guest roles\n* Changesets: browse changes to any page/media, see diffs, easily revert if necessary\n\n## Screenshots\n\n#### Front-end:\n\n\u003ca href=\"https://user-images.githubusercontent.com/604496/46574247-037d4f00-c9a9-11e8-8585-0d574dda2600.png\"\u003e\u003cimg src=\"https://user-images.githubusercontent.com/604496/46574252-1859e280-c9a9-11e8-821f-daeaaac7de3f.png\" /\u003e\u003c/a\u003e\n\u003ca href=\"https://user-images.githubusercontent.com/604496/46574259-2c054900-c9a9-11e8-8ecc-ca542053f665.png\"\u003e\u003cimg src=\"https://user-images.githubusercontent.com/604496/46574288-9a4a0b80-c9a9-11e8-8373-2a7d3e00289c.png\" /\u003e\u003c/a\u003e\n\u003ca href=\"https://user-images.githubusercontent.com/604496/46574262-31629380-c9a9-11e8-9ea6-18fbe63f239f.png\"\u003e\u003cimg src=\"https://user-images.githubusercontent.com/604496/46574291-9f0ebf80-c9a9-11e8-8656-8a54dd2f2be7.png\" /\u003e\u003c/a\u003e\n\n#### Admin panel:\n\n\u003ca href=\"https://user-images.githubusercontent.com/604496/46574266-3f181900-c9a9-11e8-828d-9d9a5db25acb.png\"\u003e\u003cimg src=\"https://user-images.githubusercontent.com/604496/46574292-a209b000-c9a9-11e8-8193-cd99fc1f5f91.png\" /\u003e\u003c/a\u003e\n\u003ca href=\"https://user-images.githubusercontent.com/604496/46574268-43443680-c9a9-11e8-974f-f8a60fbeaa74.png\"\u003e\u003cimg src=\"https://user-images.githubusercontent.com/604496/46574297-a504a080-c9a9-11e8-8612-d3e5cd1592a4.png\" /\u003e\u003c/a\u003e\n\n## Installation via Docker\n1. Download the [docker-compose.lite.yml](docker-compose.lite.yml).\n\n2. Set the locale to English:\n\n   Modify `docker-compose.lite.yml`:\n   Change `Locale=ru-RU` to `Locale=en-US`.\n\n3. _Optional_: \n\n    Configure your Bonsai instance to use HTTPS for better security.\n\n    You can use any vendor-specific options: e.g. Cloudflare Tunnel (free, fairly easy to configure, but requires a domain), Synology DDNS (free, very easy, requires a Synology NAS device), etc.\n\n    This requires a bit of work, so if you just want to give Bonsai a quick spin - feel free to skip or postpone this one and the next.\n\n4. _Optional_:\n\n    Create a [Google Authorization app](https://docs.microsoft.com/en-us/aspnet/core/security/authentication/social/google-logins?view=aspnetcore-6.0) (or Yandex / VK.com).\n\n    Modify `docker-compose.lite.yml`:\n\n    * Save Google authorization credentials to `Auth__Google__ClientId` and `Auth__Google__ClientSecret` config properties\n    * Set `Auth__AllowPasswordAuth=false` if you want to disable the less-secure password authorization\n\n5. Bring everything up using `docker compose`:\n   ```\n   docker-compose -f docker-compose.lite.yml up -d\n   ```\n6. After everything is brought up Bonsai will listen on port `8080`.\n\n## Development (on Windows)\n\nFor development, you will need the following:\n\n* [.NET 9](https://dotnet.microsoft.com/en-us/download/dotnet/9.0): the main runtime for Bonsai\n\n1. Install [NodeJS 14](https://nodejs.org/en/)\n2. Download [ffmpeg shared binaries](https://www.ffmpeg.org/download.html) for your system and extract the archive's contents into `External/ffmpeg` folder in the solution root (must contain both `ffmpeg` and `ffprobe` executables).\n3. Create a file called `appsettings.Development.json`, add the connection string:\n\n    ```\n    {\n      \"ConnectionStrings\": {\n        \"EmbeddedDatabase\": \"Data Source=App_Data/bonsai.db\",\n        \"UseEmbeddedDatabase\": true\n      },\n      \"Auth\": {\n        \"AllowPasswordAuth\": true\n      } \n    }\n    ```\n\n5. _Optional, but suggested_:\n\n    Create a [Google Authorization App](https://docs.microsoft.com/en-us/aspnet/core/security/authentication/social/google-logins?view=aspnetcore-9.0) (or Yandex / VK.com).\n\n    Add the retrieved authorization credentials to the `appsettings.Development.json` and set `AllowPasswordAuth` to `false`:\n\n    ```\n    {\n        \"Auth\": {\n            \"AllowPasswordAuth\": false,\n            \"Google\": {\n              \"ClientId\": \"\u003c...\u003e\",\n              \"ClientSecret\": \"\u003c...\u003e\" \n            },\n            \"Yandex\": {\n              \"ClientId\": \"\u003c...\u003e\",\n              \"ClientSecret\": \"\u003c...\u003e\" \n            },\n            \"Vkontakte\": {\n              \"ClientId\": \"\u003c...\u003e\",\n              \"ClientSecret\": \"\u003c...\u003e\" \n            }\n        }\n    }\n    ```\n    \n6. Create the database:\n\n    ```\n    dotnet ef database update\n    ```\n7. Build the styles and scripts:\n\n    ```\n    npm install\n    npm run build\n    ```\n8. Run the app (as Visual Studio project or using `dotnet run`).\n\n## Security considerations\n\n### Data backup\n\nIf you value the data that you store in Bonsai, make sure that you **SET UP BACKUPS**.\n\nYou will need to back up the following:\n\n* Database (approximately tens of megabytes)\n* Uploaded media in `wwwroot/media` (may contain gigabytes of data)\n\nThere are many options available, free and paid: uploading to a cloud storage, copying to external drives, etc. Please consider your usage/budget and select a combination that works best for you.\n\n### Authorization methods\n\nBonsai features two authorization methods: OAuth and password authorization.\n\nOAuth is the preferred method: it's easier to use for end users, more secure and versatile. **Please use the OAuth method if you can!**\nFor OAuth, you will need to create an authorization app on [Google](https://docs.microsoft.com/en-us/aspnet/core/security/authentication/social/google-logins?view=aspnetcore-6.0), [Vkontakte](https://vk.com/editapp?act=create), or [Yandex](https://oauth.yandex.ru/client/new) as described in the installation steps.\nYou can enable multiple authorization apps at the same time: users will pick the one they prefer.\n\nAs a fallback, you can also create an account with classic login/password authorization. It can be used for two purposes:\n\n* Playing around with Bonsai (easier to set up: no auth app and https configuration required)\n* Giving access to elder family members who don't have a social network account\n\nPlease keep the following facts in mind:\n\n* Any user account can only have one authorization method: password, or Facebook, or Google, etc.\n* It is not possible to change the authorization type for an account once it has been created.\n* Password-based accounts can be locked out if there are too many consecutive failed login attempts.\n* Account password can only be reset by an administrator manually. If you only have one admin account, it is password-based, and the password is lost - there's no way to regain access besides direct database manipulation!","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimpworks%2Fbonsai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fimpworks%2Fbonsai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimpworks%2Fbonsai/lists"}