Skip to content

FurqanSoftware/bullet

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

186 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bullet

Bullet is a fast and flexible application deployment tool built by Furqan Software. It automates the full lifecycle of deploying containerized applications to remote servers over SSH, without the overhead of a full orchestration platform.

Features

  • Server setup: Installs Docker and prepares remote servers for deployments.
  • Tarball-based deploys: Packages application code into tarballs, uploads them over SCP, and builds Docker images on the server.
  • Program management: Define multiple programs (e.g. web, worker) per application, each running in its own container.
  • Scaling: Scale programs up or down with expression-based rules that can factor in host tags and hardware.
  • Cron jobs: Manage scheduled tasks backed by systemd timers, with optional healthcheck pings.
  • Zero-downtime reloads: Reload containers via signal, command, or restart, with support for pre-reload hooks.
  • Environment management: Push environment files to servers.
  • Log tailing: Tail container logs directly from the CLI.
  • Port forwarding: Forward remote ports to your local machine over SSH.
  • Host access: Open an interactive shell, view disk usage, or run top on remote servers.
  • Multi-node support: Target multiple hosts per deployment with interactive node selection.
  • Release pruning: Clean up old releases to free disk space.

Getting Started

Install

From source:

go install github.com/FurqanSoftware/bullet@latest

Or download a prebuilt binary from the Releases page.

Define a Bulletspec

Create a Bulletspec file in your project root. This defines your application and its programs:

application:
  name: Hello World
  identifier: hello

  programs:
    web:
      name: Hello World Web Server
      command: node index.js
      container:
        image: node:8.1-alpine
      ports:
        - 80:5000

Configure Hosts

Pass hosts directly via flags:

bullet -H 192.168.0.3 <command>

Or create a Bulletcfg.<name> file:

hosts: 192.168.0.3,192.168.0.4
port: 22

Then use it with:

bullet -c <name> <command>

You can also set hosts via environment variables:

export BULLET_HOSTS=192.168.0.3

Set Up a Server

bullet -H 192.168.0.3 setup

This installs Docker and prepares the server for deployments.

Deploy

Package your application as a tarball and deploy:

tar czf app.tar.gz <your files>
bullet -H 192.168.0.3 deploy app.tar.gz

Scale Programs

bullet -H 192.168.0.3 scale web=2

Commands

bullet deploy [tarball]          # Deploy a release (--setup, --environ, --scale)
bullet setup                     # Prepare servers for deployment
bullet status                    # Show container status across nodes
bullet restart                   # Restart all application containers
bullet run [program]             # Run a one-off program container
bullet scale [program=count ...] # Scale program instances
bullet log [program[:instance]]  # Tail container logs
bullet cron:enable [job ...]     # Enable cron jobs
bullet cron:disable [job ...]    # Disable cron jobs
bullet cron:status               # Show cron job status
bullet environ:push [file]       # Push an environment file to servers
bullet forward [local:]remote    # Forward a remote port locally
bullet prune                     # Remove old releases
bullet host:shell                # Open an interactive shell on a server
bullet host:df                   # Show disk usage on a server
bullet host:top                  # Show running processes on a server

See the docs/ directory for detailed documentation.

Shell Completion

Bullet supports autocompletion for bash, zsh, fish, and powershell. It completes command names, flag values (e.g. -c from Bulletcfg.* files), and arguments (e.g. program keys and cron job keys from Bulletspec).

To enable it, add the following to your shell configuration:

Bash (~/.bashrc):

eval "$(bullet completion bash)"

Zsh (~/.zshrc):

eval "$(bullet completion zsh)"

Fish (~/.config/fish/config.fish):

bullet completion fish | source

PowerShell:

bullet completion powershell | Out-String | Invoke-Expression

But, Kubernetes?

https://k8s.af/

Acknowledgements

About

Bullet is a fast and flexible application deploy tool built by Furqan Software.

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages