# How EarnFM Fleetshare Mode Differs from Standard Proxy Mode in InternetIncome

> Understand the key differences between EarnFM Fleetshare mode and standard proxy mode in InternetIncome. Discover how Fleetshare aggregates SOCKS5 proxies for efficient resource utilization.

- Repository: [engageub/internetincome](https://github.com/engageub/internetincome)
- Tags: deep-dive
- Published: 2026-03-01

---

**EarnFM Fleetshare mode aggregates multiple SOCKS5 proxies into a single container via a JSON configuration file, while standard mode runs an isolated client that operates independently of any proxy files.**

InternetIncome supports two distinct EarnFM deployment strategies controlled by the `USE_EARN_FM_FLEETSHARE` flag in [`properties.conf`](https://github.com/engageub/internetincome/blob/main/properties.conf). Understanding the architectural differences between standard client mode and Fleetshare mode is essential for optimizing proxy utilization, reducing container overhead, and maximizing bandwidth monetization efficiency.

## Core Architectural Differences

The fundamental distinction lies in how each mode handles network traffic and proxy resources.

### Standard EarnFM Client Mode

In standard mode, the container runs as a standalone client using the `earnfm/earnfm-client:latest` image. It connects directly to EarnFM's servers using only the API token provided via environment variables. This mode does not read, mount, or utilize any external [`proxies.txt`](https://github.com/engageub/internetincome/blob/main/proxies.txt) file. The container operates in isolation, making it suitable for single-device deployments where proxy aggregation is unnecessary.

### EarnFM Fleetshare Mode

Fleetshare mode transforms the container into a proxy aggregation hub using the `earnfm/fleetshare:latest` image. Instead of running independently, this mode consumes the entire [`proxies.txt`](https://github.com/engageub/internetincome/blob/main/proxies.txt) file, parses every `socks5://` entry, and compiles them into a JSON configuration array. The script then mounts this generated configuration into the container at [`/app/config.json`](https://github.com/engageub/internetincome/blob/main//app/config.json), allowing the Fleetshare client to rotate through and monetize all supplied SOCKS5 proxies sequentially.

## Configuration and Activation Logic

The activation logic resides in [`internetIncome.sh`](https://github.com/engageub/internetincome/blob/main/internetIncome.sh), where conditional statements determine which branch executes based on the `USE_EARN_FM_FLEETSHARE` value set in [`properties.conf`](https://github.com/engageub/internetincome/blob/main/properties.conf) (lines 50-53).

For standard mode, the script evaluates:

```bash
if [[ $EARN_FM_API && "$USE_EARN_FM_FLEETSHARE" != true ]]; then

```

This branch triggers when the flag is **false** or unset (lines 48-50).

For Fleetshare mode, the condition requires explicit activation:

```bash
if [[ $EARN_FM_API && "$USE_EARN_FM_FLEETSHARE" = true ]]; then

```

This branch executes only when the flag is explicitly set to **true** (lines 67-69).

## Docker Image and Container Strategy

Each mode pulls and runs a distinct Docker image optimized for its specific architecture.

**Standard Mode Image:**
- `earnfm/earnfm-client:latest`
- Lightweight client designed for single-token, direct-connection scenarios
- No volume mounts required for proxy configuration

**Fleetshare Mode Image:**
- `earnfm/fleetshare:latest`
- Designed to ingest external proxy configurations via file mount
- Requires read access to the generated [`earnfm_config.json`](https://github.com/engageub/internetincome/blob/main/earnfm_config.json)

## Proxy Handling Mechanisms

The proxy handling logic represents the most significant operational difference between the two modes.

In **standard mode**, the script passes only the API token as an environment variable:

```bash
docker run -d \
  --name earnfm$UNIQUE_ID$i \
  --restart=always $NETWORK_TUN $LOGS_PARAM $DNS_VOLUME \
  -e EARNFM_TOKEN=$EARN_FM_API \
  earnfm/earnfm-client:latest

```

The container ignores any [`proxies.txt`](https://github.com/engageub/internetincome/blob/main/proxies.txt) file present in the working directory.

In **Fleetshare mode**, the script performs a multi-step proxy aggregation process (lines 73-95):

1. **Validation**: Checks for [`proxies.txt`](https://github.com/engageub/internetincome/blob/main/proxies.txt) existence
2. **Parsing**: Iterates through each line, extracting entries starting with `socks5://`
3. **Transformation**: Strips the `socks5://` prefix from each entry
4. **Compilation**: Builds a JSON structure with `apiKey` and a `devices.socksProxies` array
5. **Persistence**: Writes the configuration to [`earnfm_config.json`](https://github.com/engageub/internetincome/blob/main/earnfm_config.json)

The resulting configuration file looks like:

```json
{
  "apiKey": "your-token-here",
  "devices": {
    "subnets": [],
    "socksProxies": [
      "user:pass@1.2.3.4:1080",
      "5.6.7.8:1080"
    ]
  },
  "debug": false
}

```

The container then mounts this file:

```bash
docker run -d \
  --name earnfm$UNIQUE_ID$i \
  --restart=always $LOGS_PARAM $DNS_VOLUME \
  --mount type=bind,source=$PWD/earnfm_config.json,target=/app/config.json \
  earnfm/fleetshare:latest

```

## Practical Implementation Examples

### Standard Mode Setup

Configure [`properties.conf`](https://github.com/engageub/internetincome/blob/main/properties.conf):

```bash
USE_EARN_FM_FLEETSHARE=false
EARN_FM_API='your-api-token-here'

```

Execute the launcher:

```bash
./internetIncome.sh

```

The script deploys isolated `earnfm/earnfm-client` containers that connect directly to EarnFM servers.

### Fleetshare Mode Setup

Configure [`properties.conf`](https://github.com/engageub/internetincome/blob/main/properties.conf):

```bash
USE_EARN_FM_FLEETSHARE=true
EARN_FM_API='your-api-token-here'

```

Prepare [`proxies.txt`](https://github.com/engageub/internetincome/blob/main/proxies.txt) with SOCKS5 endpoints:

```text
socks5://user:pass@192.168.1.100:1080
socks5://203.0.113.45:1080
socks5://198.51.100.22:1080

```

Execute the launcher:

```bash
./internetIncome.sh

```

The script generates [`earnfm_config.json`](https://github.com/engageub/internetincome/blob/main/earnfm_config.json) containing all three proxies and launches a single `earnfm/fleetshare` container that monetizes the entire proxy fleet.

## Summary

- **Standard EarnFM mode** runs `earnfm/earnfm-client:latest` as an isolated container using only an API token, ignoring any proxy files.
- **Fleetshare mode** runs `earnfm/fleetshare:latest` and aggregates all SOCKS5 proxies from [`proxies.txt`](https://github.com/engageub/internetincome/blob/main/proxies.txt) into a JSON configuration file mounted at [`/app/config.json`](https://github.com/engageub/internetincome/blob/main//app/config.json).
- Activation is controlled by the `USE_EARN_FM_FLEETSHARE` boolean in [`properties.conf`](https://github.com/engageub/internetincome/blob/main/properties.conf) (lines 50-53), evaluated in [`internetIncome.sh`](https://github.com/engageub/internetincome/blob/main/internetIncome.sh) at lines 48-50 (standard) and 67-69 (Fleetshare).
- Fleetshare reduces container overhead by consolidating multiple proxy connections into a single EarnFM instance, while standard mode provides direct, unproxied connectivity.

## Frequently Asked Questions

### What configuration flag enables EarnFM Fleetshare mode?

The `USE_EARN_FM_FLEETSHARE` flag in [`properties.conf`](https://github.com/engageub/internetincome/blob/main/properties.conf) controls the mode. Set it to `true` to enable Fleetshare mode, which triggers the proxy aggregation logic in [`internetIncome.sh`](https://github.com/engageub/internetincome/blob/main/internetIncome.sh) (lines 67-69). When set to `false` or unset, the script defaults to standard client mode (lines 48-50).

### Does standard EarnFM mode use the proxies.txt file?

No. Standard mode completely ignores [`proxies.txt`](https://github.com/engageub/internetincome/blob/main/proxies.txt). The `earnfm/earnfm-client:latest` container receives only the `EARNFM_TOKEN` environment variable and establishes direct connections to EarnFM servers without routing through external SOCKS5 proxies.

### Which Docker image should I use for proxy aggregation?

Use `earnfm/fleetshare:latest` when you need to aggregate multiple SOCKS5 proxies. This image expects a mounted JSON configuration file at [`/app/config.json`](https://github.com/engageub/internetincome/blob/main//app/config.json) containing a `socksProxies` array. The standard image (`earnfm/earnfm-client:latest`) does not support proxy aggregation and runs as a standalone client.

### Can I run both EarnFM modes simultaneously?

Technically, you could run separate instances of InternetIncome with different [`properties.conf`](https://github.com/engageub/internetincome/blob/main/properties.conf) configurations, but a single execution of [`internetIncome.sh`](https://github.com/engageub/internetincome/blob/main/internetIncome.sh) processes only one mode per run based on the `USE_EARN_FM_FLEETSHARE` value. To run both simultaneously, you would need to maintain separate working directories or modify the script logic to avoid container name collisions (`earnfm$UNIQUE_ID$i`).