{"id":15011433,"url":"https://github.com/mati365/hetzner-podman-bunjs-deploy","last_synced_at":"2025-04-12T03:31:06.929Z","repository":{"id":197616216,"uuid":"698910115","full_name":"Mati365/hetzner-podman-bunjs-deploy","owner":"Mati365","description":"Example of standalone application deployment to Hetzner Cloud using Rootless Podman quadlet systemd services and Ansible as IaC","archived":false,"fork":false,"pushed_at":"2025-01-08T09:04:24.000Z","size":64,"stargazers_count":54,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-25T23:22:49.048Z","etag":null,"topics":["ansible","ansible-playbook","bunjs","ci","deployment","docker","hetzner","hetzner-cloud","iac","node","node-js","nodejs","quadlet","raspberrypi","systemd","vps","vps-setup"],"latest_commit_sha":null,"homepage":"","language":"Jinja","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/Mati365.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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}},"created_at":"2023-10-01T11:03:49.000Z","updated_at":"2025-03-24T14:19:10.000Z","dependencies_parsed_at":"2023-10-01T19:39:04.245Z","dependency_job_id":"3f2efefa-234e-4aa8-bdd0-bac21368f587","html_url":"https://github.com/Mati365/hetzner-podman-bunjs-deploy","commit_stats":{"total_commits":12,"total_committers":1,"mean_commits":12.0,"dds":0.0,"last_synced_commit":"8a5e979702412e300d08ad121cef211303865044"},"previous_names":["mati365/hetzner-podman-node-deploy"],"tags_count":0,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mati365%2Fhetzner-podman-bunjs-deploy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mati365%2Fhetzner-podman-bunjs-deploy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mati365%2Fhetzner-podman-bunjs-deploy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mati365%2Fhetzner-podman-bunjs-deploy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Mati365","download_url":"https://codeload.github.com/Mati365/hetzner-podman-bunjs-deploy/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248512528,"owners_count":21116617,"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":["ansible","ansible-playbook","bunjs","ci","deployment","docker","hetzner","hetzner-cloud","iac","node","node-js","nodejs","quadlet","raspberrypi","systemd","vps","vps-setup"],"created_at":"2024-09-24T19:41:05.529Z","updated_at":"2025-04-12T03:31:06.924Z","avatar_url":"https://github.com/Mati365.png","language":"Jinja","funding_links":[],"categories":[],"sub_categories":[],"readme":"# hetzner-podman-bun-deploy\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg?style=flat-square)](https://opensource.org/licenses/MIT)\n![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/mati365/hetzner-podman-bunjs-deploy?style=flat-square)\n![GitHub issues](https://img.shields.io/github/issues/mati365/hetzner-podman-bunjs-deploy?style=flat-square)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com)\n\nExample of standalone Bun.js application deployment to Hetzner Cloud using Rootless Podman Quadlet systemd services. It can be used also as an simple alternative deployment method for Raspberry Pi. \n\n## Description\n\nThe project shows an example deployment of a Bun.js (and possibly Node.js) application using Ansible to a Hetzner VPS.\n\nThe infrastructure consists of:\n\n1. Hetzner ARM CAX11 server (provision made by Ansible)\n2. NGINX and Letsencrypt\n3. Fish Shell\n4. Podman Quadlet containers that runs under deploy user with autoupdate containers\n5. Docker registry\n\nTake a look at container file: https://github.com/Mati365/hetzner-podman-bunjs-deploy/blob/main/infra/roles/apps/frontend/tasks/main.yml\n\n## How to run it?\n\n1. Create empty project on hetzner.com, add primary IP named `app-primary-ip`\n2. Point your DNS to `app-primary-ip` IPv4 address\n3. Set these envs:\n\n    ```bash\n      HCLOUD_KEY: \u003cyour hcloud read \u0026 write key\u003e\n      REGISTRY_USERNAME: \u003cspecify username for podman registry\u003e\n      REGISTRY_PASSWORD: \u003cspecify password for podman registry\u003e\n      WEBSITE_DOMAIN: \u003cspecify site domain name without protocol e.g `example.site.org`\u003e\n    ```\n\n4. Paste your public SSH keys to all users dirs present in `infra/keys/authorized/`\n5. Run `deploy-hetzner.yml` workflow by `git push origin main:hetzner`\n6. Enter your `Hello World` site and enjoy!\n\n## Useful links\n\nhttps://www.redhat.com/sysadmin/quadlet-podman \u003cbr /\u003e\nhttps://www.redhat.com/sysadmin/podman-auto-updates-rollbacks \u003cbr /\u003e\nhttps://docs.podman.io/en/latest/markdown/podman-auto-update.1.html\n\n## License\n\nMIT License\n\nCopyright (c) 2023 Mateusz Bagiński\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmati365%2Fhetzner-podman-bunjs-deploy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmati365%2Fhetzner-podman-bunjs-deploy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmati365%2Fhetzner-podman-bunjs-deploy/lists"}