feat(docker): 🚀 Update server port to 8025
Some checks failed
CI / Test (1.22) (push) Failing after -24m19s
CI / Test (1.23) (push) Failing after -24m15s
CI / Lint (push) Successful in -26m35s
CI / Build (push) Successful in -26m34s

- Change default server port from 8080 to 8025 across all configurations.
- Update Dockerfile, docker-compose.yml, and related documentation.
- Ensure all CLI commands and API endpoints reflect the new port.
- Adjust example configurations and health check URLs accordingly.
This commit is contained in:
Hein
2026-02-04 13:37:38 +02:00
parent 947761313b
commit c1dbff318d
16 changed files with 270 additions and 125 deletions

40
CLI.md
View File

@@ -52,7 +52,7 @@ Create a configuration file at `~/.whatshooked/cli.json`:
```json
{
"server_url": "http://localhost:8080",
"server_url": "http://localhost:8025",
"auth_key": "your-api-key-here",
"username": "",
"password": ""
@@ -63,7 +63,7 @@ Or use API key authentication:
```json
{
"server_url": "http://localhost:8080",
"server_url": "http://localhost:8025",
"auth_key": "your-secure-api-key"
}
```
@@ -72,7 +72,7 @@ Or use username/password authentication:
```json
{
"server_url": "http://localhost:8080",
"server_url": "http://localhost:8025",
"username": "admin",
"password": "your-secure-password"
}
@@ -90,14 +90,14 @@ cp .whatshooked-cli.example.json .whatshooked-cli.json
Set environment variables (useful for CI/CD):
```bash
export WHATSHOOKED_SERVER_URL="http://localhost:8080"
export WHATSHOOKED_SERVER_URL="http://localhost:8025"
export WHATSHOOKED_AUTH_KEY="your-api-key-here"
```
Or with username/password:
```bash
export WHATSHOOKED_SERVER_URL="http://localhost:8080"
export WHATSHOOKED_SERVER_URL="http://localhost:8025"
export WHATSHOOKED_USERNAME="admin"
export WHATSHOOKED_PASSWORD="your-password"
```
@@ -107,7 +107,7 @@ export WHATSHOOKED_PASSWORD="your-password"
Pass credentials via command-line flags:
```bash
./bin/whatshook-cli --server http://localhost:8080 health
./bin/whatshook-cli --server http://localhost:8025 health
```
Note: Currently, authentication credentials can only be set via config file or environment variables. Command-line flags for auth credentials may be added in future versions.
@@ -118,7 +118,7 @@ If your server doesn't require authentication, simply omit the authentication fi
```json
{
"server_url": "http://localhost:8080"
"server_url": "http://localhost:8025"
}
```
@@ -134,12 +134,12 @@ The CLI looks for configuration files in the following locations (in order):
### Configuration Options
| Option | Type | Default | Description |
|--------|------|---------|-------------|
| `server_url` | string | `http://localhost:8080` | WhatsHooked server URL |
| `auth_key` | string | `""` | API key for authentication |
| `username` | string | `""` | Username for Basic Auth |
| `password` | string | `""` | Password for Basic Auth |
| Option | Type | Default | Description |
| ------------ | ------ | ----------------------- | -------------------------- |
| `server_url` | string | `http://localhost:8025` | WhatsHooked server URL |
| `auth_key` | string | `""` | API key for authentication |
| `username` | string | `""` | Username for Basic Auth |
| `password` | string | `""` | Password for Basic Auth |
## Commands
@@ -178,6 +178,7 @@ Add a new webhook interactively:
```
You'll be prompted for:
- Hook ID
- Hook Name
- Webhook URL
@@ -188,6 +189,7 @@ You'll be prompted for:
**Available Event Types:**
WhatsApp Connection Events:
- `whatsapp.connected` - WhatsApp client connected
- `whatsapp.disconnected` - WhatsApp client disconnected
- `whatsapp.qr.code` - QR code generated for pairing
@@ -198,6 +200,7 @@ WhatsApp Connection Events:
- `whatsapp.pair.event` - Generic pairing event
Message Events:
- `message.received` - Message received from WhatsApp
- `message.sent` - Message sent successfully
- `message.failed` - Message sending failed
@@ -205,6 +208,7 @@ Message Events:
- `message.read` - Message read by recipient
Hook Events:
- `hook.triggered` - Hook was triggered
- `hook.success` - Hook executed successfully
- `hook.failed` - Hook execution failed
@@ -239,6 +243,7 @@ Add a new WhatsApp account interactively:
```
You'll be prompted for:
- Account ID
- Phone Number (with country code, e.g., +1234567890)
- Session Path (where to store session data)
@@ -256,6 +261,7 @@ Send a text message interactively:
```
You'll be prompted for:
- Account ID
- Recipient (phone number or JID)
- Message text
@@ -299,7 +305,7 @@ Supported formats: PDF, DOC, DOCX, XLS, XLSX, TXT, ZIP, and more
mkdir -p ~/.whatshooked
cat > ~/.whatshooked/cli.json <<EOF
{
"server_url": "http://localhost:8080",
"server_url": "http://localhost:8025",
"auth_key": "my-secure-api-key"
}
EOF
@@ -315,7 +321,7 @@ EOF
```bash
# Set environment variables
export WHATSHOOKED_SERVER_URL="https://my-server.com:8080"
export WHATSHOOKED_SERVER_URL="https://my-server.com:8025"
export WHATSHOOKED_AUTH_KEY="production-api-key"
# Use CLI without config file
@@ -375,7 +381,7 @@ export WHATSHOOKED_AUTH_KEY="production-api-key"
{
"server": {
"host": "0.0.0.0",
"port": 8080,
"port": 8025,
"auth_key": "super-secret-production-key"
}
}
@@ -452,7 +458,7 @@ cp .whatshooked-cli.example.json ~/.whatshooked/cli.json
Verify the server is running:
```bash
curl http://localhost:8080/health
curl http://localhost:8025/health
```
### Authentication Required