{"id":27185001,"url":"https://github.com/threefoldtech/zinit","last_synced_at":"2025-07-25T07:33:45.744Z","repository":{"id":41829973,"uuid":"182997281","full_name":"threefoldtech/zinit","owner":"threefoldtech","description":"A init replacement that feels like runit written in rust+tokio","archived":false,"fork":false,"pushed_at":"2025-05-31T10:23:26.000Z","size":572,"stargazers_count":11,"open_issues_count":15,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-05-31T22:52:18.307Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","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/threefoldtech.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,"zenodo":null}},"created_at":"2019-04-23T11:06:57.000Z","updated_at":"2025-05-31T10:23:29.000Z","dependencies_parsed_at":"2025-05-31T11:55:11.246Z","dependency_job_id":"007c3ac2-76cf-482b-bc3e-cc48571ea224","html_url":"https://github.com/threefoldtech/zinit","commit_stats":null,"previous_names":[],"tags_count":27,"template":false,"template_full_name":null,"purl":"pkg:github/threefoldtech/zinit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/threefoldtech%2Fzinit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/threefoldtech%2Fzinit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/threefoldtech%2Fzinit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/threefoldtech%2Fzinit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/threefoldtech","download_url":"https://codeload.github.com/threefoldtech/zinit/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/threefoldtech%2Fzinit/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266973194,"owners_count":24014633,"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-25T02:00:09.625Z","response_time":70,"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":"2025-04-09T17:10:00.102Z","updated_at":"2025-07-25T07:33:45.735Z","avatar_url":"https://github.com/threefoldtech.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Zinit [![Rust](https://github.com/threefoldtech/zinit/actions/workflows/rust.yml/badge.svg)](https://github.com/threefoldtech/zinit/actions/workflows/rust.yml)\n\nZinit is a lightweight PID 1 replacement inspired by runit, written in Rust using Tokio for async I/O. It provides both a Unix socket interface and an HTTP API for interacting with the process manager.\n\n### Key Features\n\n- **Service Management**: Ensures configured services are up and running at all times\n- **Dependency Handling**: Supports service dependencies for proper startup ordering\n- **Simple Control Interface**: Provides an intuitive CLI to add, start, stop, and monitor services\n- **Container Support**: Can run in container mode with appropriate signal handling\n- **Configurable Logging**: Multiple logging options including ringbuffer and stdout\n\n## Installation\n\n```bash\ncurl https://raw.githubusercontent.com/threefoldtech/zinit/refs/heads/master/install.sh | bash\n\n#to install \u0026 run\ncurl https://raw.githubusercontent.com/threefoldtech/zinit/refs/heads/master/install_run.sh | bash\n```\n\nClick [here](docs/installation.md) for more information on how to install Zinit.\n\n## Usage\n\n### Process Manager (zinit)\n\n```bash\n# Run zinit in init mode\nzinit init --config /etc/zinit/ --socket /var/run/zinit.sock\n\n# List services\nzinit list\n\n# Start a service\nzinit start \u003cservice-name\u003e\n\n# Stop a service\nzinit stop \u003cservice-name\u003e\n```\n\n```bash\n# Start the HTTP proxy on the default port (8080)\nzinit proxy\n```\n\nMore information about all the available commands can be found [here](docs/cmd.md).\n\n### Service Configuration\n\nZinit uses YAML files for service configuration. Here's a basic example:\n\n```yaml\n# Service configuration (e.g., /etc/zinit/myservice.yaml)\nexec: \"/usr/bin/myservice --option value\"   # Command to run (required)\ntest: \"/usr/bin/check-myservice\"            # Health check command (optional)\noneshot: false                              # Whether to restart on exit (default: false)\nafter:                                      # Services that must be running first (optional)\n  - dependency1\n  - dependency2\n```\n\nFor more information on how to configure service files, see the [service file reference](docs/services.md) documentation.\n\n### JSON-RPC API\n\nThe HTTP proxy provides a JSON-RPC 2.0 API for interacting with Zinit. You can send JSON-RPC requests to the HTTP endpoint you provided to the proxy:\n\n```bash\ncurl -X POST -H \"Content-Type: application/json\" -d '{\"jsonrpc\":\"2.0\",\"id\":1,\"method\":\"service_list\",\"params\":{}}' http://localhost:8080/\n```\n\nSee the [OpenRPC specs](openrpc.json) for more information about available RPC calls to interact with Zinit.\n\n## License\n\nSee [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthreefoldtech%2Fzinit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthreefoldtech%2Fzinit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthreefoldtech%2Fzinit/lists"}