{"id":15962299,"url":"https://github.com/albertogeniola/angular-hello-addon","last_synced_at":"2025-09-12T10:42:52.049Z","repository":{"id":47064606,"uuid":"352750308","full_name":"albertogeniola/angular-hello-addon","owner":"albertogeniola","description":null,"archived":false,"fork":false,"pushed_at":"2021-09-15T04:55:33.000Z","size":1115,"stargazers_count":5,"open_issues_count":1,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-07T13:05:39.418Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/albertogeniola.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}},"created_at":"2021-03-29T18:45:05.000Z","updated_at":"2024-09-13T21:12:45.000Z","dependencies_parsed_at":"2022-09-03T17:12:07.885Z","dependency_job_id":null,"html_url":"https://github.com/albertogeniola/angular-hello-addon","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":"issacg/hassio-addon-devcontainer","purl":"pkg:github/albertogeniola/angular-hello-addon","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/albertogeniola%2Fangular-hello-addon","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/albertogeniola%2Fangular-hello-addon/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/albertogeniola%2Fangular-hello-addon/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/albertogeniola%2Fangular-hello-addon/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/albertogeniola","download_url":"https://codeload.github.com/albertogeniola/angular-hello-addon/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/albertogeniola%2Fangular-hello-addon/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274800049,"owners_count":25352173,"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-09-12T02:00:09.324Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","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":[],"created_at":"2024-10-07T16:02:43.420Z","updated_at":"2025-09-12T10:42:52.024Z","avatar_url":"https://github.com/albertogeniola.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Hello Angular Addon\nSimple Addon showcasing an Angular app behind nginx proxy \n\n### Summary\nI did have some hard time to create a custom Homeassistant addon web-ui using a the new ingress functionality introduced with HA.\nIn particular, the problem lied on the ingress uri path to rewrite. \n\nThanks to the help received by @pvizeli, I was able to fix the issue. This repo was born as issue showcase, but it has now been updated with\nrewrite logic to make it work as expected. Therefore, I'll leave this repo available to eveyron who needs some sort of easy example to start\nwith.\n\n### Ok, but what was the problem?\nSimply put, the problem was to correctly map the relative paths to the angular app. \nThe ingress logic of HA does \"generate\" an _addon_uri_ randomly and the angular app should be able to change its base-path accordingly.\n\nAt the time of writing, the generated ingress uri path is in the following form `/api/hassio_ingress/\u003csome_token\u003e/`. The `\u003csome_token\u003e` part is randomly generated.\nAt boot time, the addon should configure the angular app so that such path is \"prepended\" to the angular app routing. \n\nTo do so, there are two possible approaches\n1. Implement the relative path within angular (e.g. change the base-path) and, at boot time, implement some sort of SED/REPLACE system to change the base-href parameters.\n1. Rely on nginx rewrite\n\nIn this repository I've implemented the second option (That allows me to be consistent at development time when implementing the app on local machine).\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falbertogeniola%2Fangular-hello-addon","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falbertogeniola%2Fangular-hello-addon","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falbertogeniola%2Fangular-hello-addon/lists"}