paste - enable content expiration
This commit is contained in:
@@ -15,8 +15,8 @@ services:
|
|||||||
environment:
|
environment:
|
||||||
- RUST_LOG=debug
|
- RUST_LOG=debug
|
||||||
volumes:
|
volumes:
|
||||||
- ./paste/data/:/app/upload
|
- ./data/:/app/upload
|
||||||
- ./paste/config.toml:/app/config.toml
|
- ./config.toml:/app/config.toml
|
||||||
networks:
|
networks:
|
||||||
- traefik
|
- traefik
|
||||||
|
|
||||||
|
|||||||
@@ -26,13 +26,14 @@ text = """
|
|||||||
├┬┘└─┐├┴┐││ │ ├─┘├─┤└─┐ │ ├┤
|
├┬┘└─┐├┴┐││ │ ├─┘├─┤└─┐ │ ├┤
|
||||||
┴└─└─┘┴ ┴┴└─┘ ┴ ┴ ┴└─┘ ┴ └─┘
|
┴└─└─┘┴ ┴┴└─┘ ┴ ┴ ┴└─┘ ┴ └─┘
|
||||||
|
|
||||||
Submit files via HTTP POST here:
|
Uploaded content expires after 24 hours and may be removed without warning.
|
||||||
|
|
||||||
|
https://raw.githubusercontent.com/rskntroot/oxpasta/refs/heads/main/oxpasta.sh
|
||||||
|
|
||||||
|
Submit files via oxpasta script or via HTTP POST:
|
||||||
curl -F 'file=@example.txt' paste.rskio.com
|
curl -F 'file=@example.txt' paste.rskio.com
|
||||||
This will return the URL of the uploaded file.
|
This will return the URL of the uploaded file.
|
||||||
|
|
||||||
Content expires 24 hours.
|
|
||||||
|
|
||||||
The content may be removed without warning.
|
|
||||||
"""
|
"""
|
||||||
#file = "index.txt"
|
#file = "index.txt"
|
||||||
content_type = "text/plain; charset=utf-8"
|
content_type = "text/plain; charset=utf-8"
|
||||||
@@ -44,19 +45,19 @@ random_url = { type = "petname", words = 2, separator = "-" }
|
|||||||
#random_url = { type = "alphanumeric", length = 6, suffix_mode = true }
|
#random_url = { type = "alphanumeric", length = 6, suffix_mode = true }
|
||||||
default_extension = "txt"
|
default_extension = "txt"
|
||||||
mime_override = [
|
mime_override = [
|
||||||
{ mime = "image/jpeg", regex = "^.*\\.jpg$" },
|
{ mime = "image/jpeg", regex = "^.*\\.jpg$" },
|
||||||
{ mime = "image/png", regex = "^.*\\.png$" },
|
{ mime = "image/png", regex = "^.*\\.png$" },
|
||||||
{ mime = "image/svg+xml", regex = "^.*\\.svg$" },
|
{ mime = "image/svg+xml", regex = "^.*\\.svg$" },
|
||||||
{ mime = "video/webm", regex = "^.*\\.webm$" },
|
{ mime = "video/webm", regex = "^.*\\.webm$" },
|
||||||
{ mime = "video/x-matroska", regex = "^.*\\.mkv$" },
|
{ mime = "video/x-matroska", regex = "^.*\\.mkv$" },
|
||||||
{ mime = "application/octet-stream", regex = "^.*\\.bin$" },
|
{ mime = "application/octet-stream", regex = "^.*\\.bin$" },
|
||||||
{ mime = "text/plain", regex = "^.*\\.(log|txt|diff|sh|rs|toml)$" },
|
{ mime = "text/plain", regex = "^.*\\.(log|txt|diff|sh|rs|toml)$" },
|
||||||
]
|
]
|
||||||
mime_blacklist = [
|
mime_blacklist = [
|
||||||
"application/x-dosexec",
|
"application/x-dosexec",
|
||||||
"application/java-archive",
|
"application/java-archive",
|
||||||
"application/java-vm",
|
"application/java-vm",
|
||||||
]
|
]
|
||||||
duplicate_files = true
|
duplicate_files = false
|
||||||
# default_expiry = "1h"
|
default_expiry = "24h"
|
||||||
delete_expired_files = { enabled = true, interval = "24h" }
|
delete_expired_files = { enabled = true, interval = "1h" }
|
||||||
|
|||||||
Reference in New Issue
Block a user