Update README.md and wrangler.toml
This commit is contained in:
parent
988fc29dda
commit
e740a54af9
18
README.md
18
README.md
@ -4,22 +4,24 @@
|
|||||||
|
|
||||||
Use Cloudflare Workers to provide a WebDav interface for Cloudflare R2.
|
Use Cloudflare Workers to provide a WebDav interface for Cloudflare R2.
|
||||||
|
|
||||||
## Configuration
|
## Usage
|
||||||
|
|
||||||
Change wrangler.toml to your own.
|
Change wrangler.toml to your own.
|
||||||
|
|
||||||
```toml
|
```toml
|
||||||
[[r2_buckets]]
|
[[r2_buckets]]
|
||||||
binding = 'webdav' # <~ valid JavaScript variable name, don't change this
|
binding = 'bucket' # <~ valid JavaScript variable name, don't change this
|
||||||
bucket_name = 'webdav'
|
bucket_name = 'webdav'
|
||||||
|
|
||||||
[vars]
|
|
||||||
USERNAME = "USERNAME"
|
|
||||||
PASSWORD = "PASSWORD"
|
|
||||||
```
|
```
|
||||||
|
|
||||||
- USERNAME: The username of WebDav.
|
Then use wrangler to deploy.
|
||||||
- PASSWORD: The password of WebDav.
|
|
||||||
|
```bash
|
||||||
|
wrangler deploy
|
||||||
|
|
||||||
|
wrangler secret put USERNAME
|
||||||
|
wrangler secret put PASSWORD
|
||||||
|
```
|
||||||
|
|
||||||
## Development
|
## Development
|
||||||
|
|
||||||
|
@ -7,9 +7,8 @@ node_compat = true
|
|||||||
# Variable bindings. These are arbitrary, plaintext strings (similar to environment variables)
|
# Variable bindings. These are arbitrary, plaintext strings (similar to environment variables)
|
||||||
# Note: Use secrets to store sensitive data.
|
# Note: Use secrets to store sensitive data.
|
||||||
# Docs: https://developers.cloudflare.com/workers/platform/environment-variables
|
# Docs: https://developers.cloudflare.com/workers/platform/environment-variables
|
||||||
[vars]
|
# [vars]
|
||||||
USERNAME = "USERNAME"
|
# MY_VARIABLE = "my-value"
|
||||||
PASSWORD = "PASSWORD"
|
|
||||||
|
|
||||||
# Bind a KV Namespace. Use KV as persistent storage for small key-value pairs.
|
# Bind a KV Namespace. Use KV as persistent storage for small key-value pairs.
|
||||||
# Docs: https://developers.cloudflare.com/workers/runtime-apis/kv
|
# Docs: https://developers.cloudflare.com/workers/runtime-apis/kv
|
||||||
|
Loading…
Reference in New Issue
Block a user