Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/Nephos/transfer_more
Fast and temporary file uploader :signal_strength: UPSTREAM ON https://git.sceptique.eu/Sceptique/transfer_more
https://github.com/Nephos/transfer_more
upload
Last synced: 30 days ago
JSON representation
Fast and temporary file uploader :signal_strength: UPSTREAM ON https://git.sceptique.eu/Sceptique/transfer_more
- Host: GitHub
- URL: https://github.com/Nephos/transfer_more
- Owner: Nephos
- License: gpl-3.0
- Created: 2016-05-19T21:12:50.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-09-09T20:06:15.000Z (over 1 year ago)
- Last Synced: 2024-08-03T17:14:06.339Z (4 months ago)
- Topics: upload
- Language: Crystal
- Homepage: https://git.sceptique.eu/Sceptique/transfer_more
- Size: 347 KB
- Stars: 16
- Watchers: 4
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-crystal - transfer_more - Clone of transfer.sh to uploads files (Network Protocols)
README
**Upstream on **
# transfer_more
Fast and lite file upload server ([transfer.sh](https://transfer.sh/) clone).
![screenshot](https://raw.githubusercontent.com/Nephos/transfer_more/master/sample.png)
- It's a simple online file sharing.
- Files older than 7 days are destroyed (configurable).
- Recognize shebangs, magic numbers, ...## Installation [![Build Status](https://drone.sceptique.eu/api/badges/Sceptique/transfer_more/status.svg)](https://drone.sceptique.eu/Sceptique/transfer_more)
Compatible crystal v1.9.2
### From source
```sh
make # build the app / deps
make test # run unit test
make doc # build the documentation
```### From AUR with yay (or yaourt etc.)
```sh
yay -S transfer-more
```### As a systemd service
[Unit]
Description=Tranfer more file sharing
Documentation=https://wiki.archlinux.org/index.php/Transfer-more[Service]
ExecStart=/usr/share/transfer-more/transfer-more --port 10003 --bind 127.0.0.1
Restart=on-failure
RestartSec=5
Environment="TRANSFER_SSL_ENABLED=true"
WorkingDirectory=/usr/share/transfer-more/# Hardening
MemoryDenyWriteExecute=true
SystemCallArchitectures=native
CapabilityBoundingSet=
NoNewPrivileges=true
RemoveIPC=true
LockPersonality=trueProtectControlGroups=true
ProtectKernelTunables=true
ProtectKernelModules=true
ProtectKernelLogs=true
ProtectClock=true
ProtectHostname=true
ProtectProc=noaccessRestrictRealtime=true
RestrictSUIDSGID=true
RestrictNamespaces=true
RestrictAddressFamilies=AF_UNIX AF_INET AF_INET6ProtectSystem=full
ProtectHome=true
PrivateDevices=true
PrivateTmp=true[Install]
WantedBy=default.target### Behind a nginx proxy
You should configure your nginx with `/etc/nginx/servers-enabled/transfer-more.conf`:
server {
listen 443 ssl;
server_name your.sub.domain;
client_max_body_size 1G;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
location / {
proxy_pass http://localhost:3000;
}
}## Usage
### Run the Server
```sh
export TRANSFER_SSL_ENABLED=true # true if the ssl is enabled, any other string is false
export TRANSFER_BASE_STORAGE="/tmp" # where the files will be kept
export TRANSFER_SECURE_SIZE=4 # how much characters to identify a file
export TRANSFER_STORAGE_DAYS=7 # how much time the files are kept
export TRANSFER_TIME_FORMAT="%y%m%d%H"
export TRANSFER_HOST_PORT="localhost:3000" # in pinciple it is auto solved using the http headers, optional
export TRANSFER_MORE_FOOTER="Something important on the bottom" # replace the default footer
export TRANSFER_MORE_TITLE="MyName upload" # replace the default title
./transfer_more
``````text
./transfer_more --help
-b HOST, --bind HOST Host to bind (defaults to 0.0.0.0)
-p PORT, --port PORT Port to listen for connections (defaults to 3000)
```### Command line client
```sh
curl --progress-bar --upload-file file.mp4 http://domain/name.mp4
```### Inside a Docker container
```sh
docker build -t transfer_more . && docker run -p 3000:3000 transfer_more
```Or with docker-compose:
```sh
docker-compose build && docker-compose up
```### [ShareX](https://github.com/ShareX) template
```json
{
"Name": "Sceptique",
"DestinationType": "ImageUploader, TextUploader, FileUploader, URLShortener",
"RequestURL": "https://up.sceptique.eu/",
"FileFormName": "file",
"Headers": {
"User-Agent": "curl"
}
}
```## Development
For now I don't have much plan expanding the feature of it, as it fulfills all my needs.
I will keep updating with each crystal new release.
## Contributing
Feel free to propose new feature anyway, we can just put them behind feature flag if it's overkill.
Review your own coding style as possible.
Do not try to include external CI in the upstream, I don't want big centralized service of the GAFAM as possible.
You can either propose a patch in an issue or open a merge request on .
You can propose it on github if you want, but git.sceptique.eu accept github OAuth so it's very quick to setup and it's my prefered way.
## Contributors
- [Sceptique](https://git.sceptique.eu/Sceptique) Arthur Poulet - creator, maintainer