{"id":18929153,"url":"https://github.com/jwillikers/unifi-controller","last_synced_at":"2025-04-15T15:30:45.306Z","repository":{"id":104839644,"uuid":"347419704","full_name":"jwillikers/unifi-controller","owner":"jwillikers","description":"A Kubernetes configuration file for running the UniFi Controller with Podman","archived":true,"fork":false,"pushed_at":"2021-03-13T20:10:28.000Z","size":24,"stargazers_count":7,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-06T21:52:14.882Z","etag":null,"topics":["containers","docker","kubernetes","kubernetes-configuration","okd","podman","systemd","unifi-controller"],"latest_commit_sha":null,"homepage":"","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jwillikers.png","metadata":{"files":{"readme":"README.adoc","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.adoc","code_of_conduct":"CODE_OF_CONDUCT.adoc","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}},"created_at":"2021-03-13T16:24:09.000Z","updated_at":"2024-02-26T19:07:30.000Z","dependencies_parsed_at":null,"dependency_job_id":"ccef6a1f-58f6-42ce-843d-52bc4b9e7a7a","html_url":"https://github.com/jwillikers/unifi-controller","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jwillikers%2Funifi-controller","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jwillikers%2Funifi-controller/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jwillikers%2Funifi-controller/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jwillikers%2Funifi-controller/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jwillikers","download_url":"https://codeload.github.com/jwillikers/unifi-controller/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249097768,"owners_count":21212349,"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":["containers","docker","kubernetes","kubernetes-configuration","okd","podman","systemd","unifi-controller"],"created_at":"2024-11-08T11:30:34.487Z","updated_at":"2025-04-15T15:30:45.301Z","avatar_url":"https://github.com/jwillikers.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"= UniFi Controller\nJordan Williams \u003cjordan@jwillikers.com\u003e\n:experimental:\n:icons: font\nifdef::env-github[]\n:tip-caption: :bulb:\n:note-caption: :information_source:\n:important-caption: :heavy_exclamation_mark:\n:caution-caption: :fire:\n:warning-caption: :warning:\nendif::[]\n:Podman: https://podman.io/[Podman]\n:podman-generate-systemd: https://docs.podman.io/en/latest/markdown/podman-generate-systemd.1.html[podman-generate-systemd(1)]\n:podman-play-kube: https://docs.podman.io/en/latest/markdown/podman-play-kube.1.html[podman-play-kube(1)]\n:systemd: https://systemd.io/[systemd]\n\nA Kubernetes configuration file for running the UniFi Controller with {Podman}.\n\n== Synopsis\n\nRun the UniFi controller in a rootless container via {Podman}, configure it as a systemd service, and automate image updates.\nThis project uses the https://github.com/linuxserver/docker-unifi-controller[docker-unifi-controller] image provided by https://www.linuxserver.io/[LinuxServer.io] and uses a Kubernetes configuration file similar to the provided docker-compose.\n\n== Getting Started\n\nThe instructions here have been tested on Ubuntu 18.04.\n\n. Follow the https://podman.io/getting-started/installation[Podman installation instructions] to install Podman.\n\n. Clone this project's Git repository.\n+\n[source,sh]\n----\n➜ git clone https://github.com/jwillikers/unifi-controller.git ~/Projects/unifi-controller\n----\n\n. Use {podman-play-kube} to create the _unifi-controller_ pod.\nThe instructions here use rootless Podman containers running under the current user for increased security.\n+\n--\n[source,sh]\n----\n➜ podman play kube ~/Projects/unifi-controller/unifi-controller.yml\n----\n\n[NOTE]\n====\nThe container will store persistent data in a Podman volume with the same name as the _Persistent Volume Claim_.\n====\n--\n\n. Access the controller's web console at https://127.0.0.1:8443/.\n\nfish::\n+\n[source,sh]\n----\n➜ open http://127.0.0.1:8443\n----\n\nOther shells::\n+\n[source,sh]\n----\n➜ xdg-open http://127.0.0.1:8443\n----\n\n== Automate\n\nPodman makes it extremely easy to set up your pods as systemd services.\nIt also offers deeper integration with systemd services within the containers themselves.\nFollow the instructions here to configure the unifi-controller pod to be managed as a service by systemd and automatically started when your user logs in.\n\n. Create the systemd directory for user units.\n+\n[source,sh]\n----\n➜ mkdir -p ~/.config/systemd/user/\n----\n\n. Change to this directory.\n+\n[source,sh]\n----\n➜ cd ~/.config/systemd/user/\n----\n\n. To view your current pods, use the following command.\n+\n[source,sh]\n----\n➜ podman pod ps\nPOD ID        NAME              STATUS   CREATED         INFRA ID      # OF CONTAINERS\na8a533215a75  unifi-controller  Running  47 minutes ago  ccf291de56ac  2\n----\n\n. Generate the systemd service unit files for the _unifi-controller_ pod with {podman-generate-systemd}.\n+\n--\nHere I generate the actual files using the `--files` option and use the `--name` option to name them using the pod name instead of the hash.\nThe `--new` option creates a new container when the service starts and destroys the container when it stops.\nThis option allows Podman to automatically apply updates to the container.\n\n[source,sh]\n----\n➜ podman generate systemd --files --name --new unifi-controller\n/home/jordan/.config/systemd/user/pod-unifi-controller.service\n/home/jordan/.config/systemd/user/container-unifi-controller_unifi-controller_1.service\n----\n--\n\n. Enable the pod's systemd service unit.\n+\n[source,sh]\n----\n➜ systemctl --user enable --now pod-unifi-controller.service\nCreated symlink /home/jordan/.config/systemd/user/multi-user.target.wants/pod-unifi-controller.service → /home/jordan/.config/systemd/user/pod-unifi-controller.service.\nCreated symlink /home/jordan/.config/systemd/user/default.target.wants/pod-unifi-controller.service → /home/jordan/.config/systemd/user/pod-unifi-controller.service.\n----\n\n. Enable automatic updates of the container image.\n+\n--\nPodman ships with both system and user auto-update timers for systemd.\nHere I enable the user timer to activate the auto-update service.\nThe timer is runs daily.\n\n[source,sh]\n----\n➜ systemctl --user enable --now podman-auto-update.timer\nCreated symlink /home/jordan/.config/systemd/user/timers.target.wants/podman-auto-update.timer → /usr/lib/systemd/user/podman-auto-update.timer.\n----\n--\n\n== Contributing\n\nContributions in the form of issues, feedback, and even pull requests are welcome.\nMake sure to adhere to the project's link:CODE_OF_CONDUCT.adoc[Code of Conduct].\n\n== Open Source Software\n\nThis project is built on the hard work of countless open source contributors.\nSeveral of these projects are enumerated below.\n\n* https://asciidoctor.org/[Asciidoctor]\n* https://www.debian.org/[Debian]\n* https://git-scm.com/[Git]\n* https://www.linuxfoundation.org/[Linux]\n* {Podman}\n* https://rouge.jneen.net/[Rouge]\n* https://www.ruby-lang.org/en/[Ruby]\n* {systemd}\n* https://ubuntu.com/[Ubuntu]\n\n== Code of Conduct\n\nThe project's Code of Conduct is available in the link:CODE_OF_CONDUCT.adoc[Code of Conduct] file.\n\n== License\n\nThis repository is licensed under the https://www.gnu.org/licenses/gpl-3.0.html[GPLv3], available in the link:LICENSE.adoc[license file].\n\n© 2021 Jordan Williams\n\n== Authors\n\nmailto:{email}[{author}]\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjwillikers%2Funifi-controller","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjwillikers%2Funifi-controller","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjwillikers%2Funifi-controller/lists"}