Setup & Configuration

 /$$                     /$$       /$$   /$$       
|__/                    | $$      |__/  | $$       
 /$$ /$$$$$$$   /$$$$$$ | $$$$$$$  /$$ /$$$$$$     
| $$| $$__  $$ |____  $$| $$__  $$| $$|_  $$_/     
| $$| $$  \ $$  /$$$$$$$| $$  \ $$| $$  | $$       
| $$| $$  | $$ /$$__  $$| $$  | $$| $$  | $$ /$$   
| $$| $$  | $$|  $$$$$$$| $$$$$$$/| $$  |  $$$$//$$
|__/|__/  |__/ \_______/|_______/ |__/   \___/ |__/

Production-ready CLI for configuring and running the Inabit Remote Approver with Docker and nginx.

Current version: v0.1.3

What you get

  • Guided setup wizard (validates token, configures URL/ports, generates nginx.conf)

  • Automatic nginx and Docker Compose configuration

  • HTTPS support with auto-detected certificates (PEM or CRT/KEY)

  • Health checks and smart troubleshooting

  • One-command cleanup and uninstall

Install (production)

Clone the release repository on your remote instance and run the installer:

Install (production)
# Clone the release bundle (contains installer + docker-compose.yml)
git clone https://your-release-repo-url.git approver-cli
cd approver-cli

# Install as current user (no sudo needed)
bash inabit-cli-installation-v1.0.sh

# Or system-wide (requires sudo)

# sudo bash inabit-cli-installation-v1.0.sh

After installation, the global command inabit is available.

Quick start

Quick start
# Run the guided setup
inabit setup

# Check status / logs
inabit status
inabit logs

# Manage services
inabit restart
inabit stop
inabit start

# Cleanup everything created by setup (keeps Docker images)
inabit cleanup

# Uninstall the CLI and remove the global "inabit" command
inabit uninstall

# For system-wide installs, use: sudo inabit uninstall

Setup flow (overview)

1

Start setup

Begin the guided setup by running inabit setup.

2

Validate login token → obtain access token

The wizard validates the provided token and obtains an access token.

3

Configure service port

Choose the approver service port (default 3020).

4

Choose network approach

Select either Domain or IP + Port.

  • Domain:

    • Choose 80 (HTTP) or 443 (HTTPS)

    • Generate nginx.conf

    • Auto-update docker-compose ports

    • Detect SSL files in ./ssl (PEM or CRT/KEY)

  • IP + Port:

    • Generate nginx.conf and map chosen port

5

Validate external URL (health check)

The setup performs health checks to validate the external URL.

6

Create directories and configuration

Setup creates required directories and configuration files.

7

Start nginx → start approver

The wizard starts nginx first, then starts the approver service.

8

Verify accessibility

The wizard verifies accessibility (accepts some transient errors like 403/502/503 during initialization).

9

Show pairing code and instructions

Finally, the setup displays the pairing code and next-step instructions.

Notes:

  • During setup, HTTP 403 from curl can be normal if Cloudflare blocks non-browser requests; browsers should work.

  • The wizard treats 403/502/503 as acceptable during early startup while the approver initializes.

Nginx in production (what the wizard configures)

  • Domain

    • Port 80 (HTTP): server { listen 80; } that proxies to approver:${APPROVER_PORT}

    • Port 443 (HTTPS):

      • listen 80; redirects HTTP to HTTPS

      • listen 443 ssl; http2 on; uses detected cert/key under /etc/nginx/ssl/

    • Docker Compose ports exposed automatically: 80:80 and 443:443

  • IP + Port

    • Single server { listen <custom>; } with proxy to approver:${APPROVER_PORT}

    • Compose port exposed automatically: <custom>:<custom>

Supported certificate pairs to place in local ssl/:

  • cert.pem + key.pem

  • cert.crt + key.key

  • server.crt + server.key

  • domain.crt + domain.key

Project structure (for reference)

Project structure
release/
├── inabit-cli-installation-v1.0.sh   # Installer
├── docker-compose.yml                # Docker services configuration
└── README.md

Prerequisites

  • Docker

  • Docker Compose

  • Bash shell

Troubleshooting

Use the CLI to inspect status, logs, and perform restarts or cleanup:

Troubleshooting commands
# Status / Logs
inabit status
inabit logs

# Restart / Cleanup
inabit restart
inabit cleanup

License

This project is part of the Inabit Remote Approver service.

Was this helpful?