Refactor port again
Some checks failed
CI / Test (1.22) (push) Failing after -24m17s
CI / Test (1.23) (push) Failing after -24m17s
CI / Build (push) Successful in -26m37s
CI / Lint (push) Successful in -26m23s

This commit is contained in:
Hein
2026-02-04 14:22:12 +02:00
parent 52241190b5
commit 592ed24204
16 changed files with 76 additions and 76 deletions

24
CLI.md
View File

@@ -52,7 +52,7 @@ Create a configuration file at `~/.whatshooked/cli.json`:
```json
{
"server_url": "http://localhost:8025",
"server_url": "http://localhost:8825",
"auth_key": "your-api-key-here",
"username": "",
"password": ""
@@ -63,7 +63,7 @@ Or use API key authentication:
```json
{
"server_url": "http://localhost:8025",
"server_url": "http://localhost:8825",
"auth_key": "your-secure-api-key"
}
```
@@ -72,7 +72,7 @@ Or use username/password authentication:
```json
{
"server_url": "http://localhost:8025",
"server_url": "http://localhost:8825",
"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:8025"
export WHATSHOOKED_SERVER_URL="http://localhost:8825"
export WHATSHOOKED_AUTH_KEY="your-api-key-here"
```
Or with username/password:
```bash
export WHATSHOOKED_SERVER_URL="http://localhost:8025"
export WHATSHOOKED_SERVER_URL="http://localhost:8825"
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:8025 health
./bin/whatshook-cli --server http://localhost:8825 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:8025"
"server_url": "http://localhost:8825"
}
```
@@ -136,7 +136,7 @@ The CLI looks for configuration files in the following locations (in order):
| Option | Type | Default | Description |
| ------------ | ------ | ----------------------- | -------------------------- |
| `server_url` | string | `http://localhost:8025` | WhatsHooked server URL |
| `server_url` | string | `http://localhost:8825` | WhatsHooked server URL |
| `auth_key` | string | `""` | API key for authentication |
| `username` | string | `""` | Username for Basic Auth |
| `password` | string | `""` | Password for Basic Auth |
@@ -305,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:8025",
"server_url": "http://localhost:8825",
"auth_key": "my-secure-api-key"
}
EOF
@@ -321,7 +321,7 @@ EOF
```bash
# Set environment variables
export WHATSHOOKED_SERVER_URL="https://my-server.com:8025"
export WHATSHOOKED_SERVER_URL="https://my-server.com:8825"
export WHATSHOOKED_AUTH_KEY="production-api-key"
# Use CLI without config file
@@ -381,7 +381,7 @@ export WHATSHOOKED_AUTH_KEY="production-api-key"
{
"server": {
"host": "0.0.0.0",
"port": 8025,
"port": 8825,
"auth_key": "super-secret-production-key"
}
}
@@ -458,7 +458,7 @@ cp .whatshooked-cli.example.json ~/.whatshooked/cli.json
Verify the server is running:
```bash
curl http://localhost:8025/health
curl http://localhost:8825/health
```
### Authentication Required