{"id":21177994,"url":"https://github.com/hexedpackets/hauler","last_synced_at":"2025-03-14T18:42:04.486Z","repository":{"id":74589019,"uuid":"39654289","full_name":"hexedpackets/hauler","owner":"hexedpackets","description":"Control and monitor Docker deployments in conjunction with Consul.","archived":false,"fork":false,"pushed_at":"2015-08-03T20:41:28.000Z","size":152,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-21T11:45:01.398Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Elixir","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/hexedpackets.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-07-24T19:57:39.000Z","updated_at":"2015-10-12T14:48:49.000Z","dependencies_parsed_at":"2023-03-01T04:16:43.225Z","dependency_job_id":null,"html_url":"https://github.com/hexedpackets/hauler","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hexedpackets%2Fhauler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hexedpackets%2Fhauler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hexedpackets%2Fhauler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hexedpackets%2Fhauler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hexedpackets","download_url":"https://codeload.github.com/hexedpackets/hauler/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243628360,"owners_count":20321848,"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":[],"created_at":"2024-11-20T17:19:28.093Z","updated_at":"2025-03-14T18:42:04.463Z","avatar_url":"https://github.com/hexedpackets.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Hauler\n\nHauler is an Elixir application for controlling and monitoring Docker deployments in conjunction with Consul. It can be controlled using either Erlang RPC calls or [BERT-RPC](https://github.com/lastcanal/aberth).\n\nBack on Cybertron, Hauler was a Constructicon involved in the building of the Crystal City. When his teammates were reprogrammed as Decepticons, Hauler turned to the Autobots, joining their ranks. This choice would eventually put him on board the Ark for its doomed voyage that ended on Earth. When he awoke with the rest of the crew in 1984, he resumed his primary function: the discovery and procurement of energy sources. This task sends him far and wide across the planet, and his tendency towards capricious self-expression often results in him coming back with different colors and parts.\n\nHis crane mode can lift 60 tons, and in robot mode, he can launch his hands from their wrist-sockets. The hands can fly through the air under his remote-control guidance, allowing him to perform tasks normally beyond his reach.\n\nHauler performs tasks related to Docker management. Clients can:\n- list all Docker containers on a node\n- start/create a container based on a config stored in Consul\n- stop and optionally destroy a container\n- recreate a container from a new image\n\n## RPCs\nRPCs are the primary way of interacting with Hauler, either from a remote Erlang process or with BERT-RPC. All functions are under the `Hauler.Server` module; from an RPC this should be called as `Elixir.Hauler.Server`. The functions available are:\n\n```elixir\nstart/2 - Creates and starts a Docker container. If the container already exists, nothing will be changed.\nstop/2 - Stops and optionally deletes a running Docker container.\nrecreate/2 - Creates and starts a new Docker container. If the container already exists, the old one will be removed first.\nlist/0 - Lists all running Docker containers.\ninspect/2 - Lookup information about a currently running container.\ncleanup/0 - Remove old images (ignoring tags). Only the most recent is kept.\ncleanup/1 - Remove old images (ignoring tags) with a specified number to keep.\nregister/1 - Store a container configuration in Consul.\nregister/2 - Store a container configuration in Consul, with a static list of nodes for deploying.\n```\n\n## Docker configuration\nHauler uses [docker-elixir](https://github.com/hexedpackets/docker-elixir) to work with the Docker API and convert JSON into a format usable with the API.\n\n## Releasing\n### Build\n- Docker must be installed and running locally. The release script uses a Linux-based Docker image; system libraries get linked in in, so an OSX/Windows based release will not be deployable on Linux.\n- Bump the version number in the VERSION file. Then from the root of the project, run `scripts/build_release.sh`\n\n### Publish\n- First build the release as instructed above\n- [github-releases](https://github.com/aktau/github-release) needs to be installed\n- The environmental variables `GITHUB_TOKEN` must be set\n- Run `scripts/push_release.sh`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhexedpackets%2Fhauler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhexedpackets%2Fhauler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhexedpackets%2Fhauler/lists"}