mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-09-18 12:30:46 +02:00
Fix markdown formatting for Enable Authentication
@@ -101,17 +101,22 @@ By default, the SeaweedFS S3 gateway starts in **"Allow All" mode** if no S3 cre
|
||||
### Enabling Authentication
|
||||
|
||||
To enable authentication for `weed mini`, use one of the following methods:
|
||||
|
||||
1. **Environment Variables**: Set `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` before starting.
|
||||
```bash
|
||||
|
||||
```bash
|
||||
export AWS_ACCESS_KEY_ID=any
|
||||
export AWS_SECRET_ACCESS_KEY=any
|
||||
export S3_ENDPOINT=http://localhost:8333
|
||||
weed mini -dir=/data
|
||||
```
|
||||
|
||||
2. **Config File**: Use the `-s3.config` flag with a JSON credentials file.
|
||||
```bash
|
||||
weed mini -dir=/data -s3.config=s3.config
|
||||
```
|
||||
|
||||
```bash
|
||||
weed mini -dir=/data -s3.config=s3.config
|
||||
```
|
||||
|
||||
3. **Dynamic Configuration**: Start normally, then add users through the **Admin UI** or **weed shell**. The server will automatically switch from "Allow All" to "Authentication Required" mode.
|
||||
|
||||
---
|
||||
|
||||
Reference in New Issue
Block a user