|
|
1 year ago | |
|---|---|---|
| css | 3 years ago | |
| font | 3 years ago | |
| img | 3 years ago | |
| includes | 1 year ago | |
| js | 1 year ago | |
| public/files | 1 year ago | |
| rain | 1 year ago | |
| .gitignore | 1 year ago | |
| LICENSE | 1 year ago | |
| README.md | 1 year ago | |
| api.php | 1 year ago | |
| error.php | 1 year ago | |
| error_meow.php | 1 year ago | |
| favicon.192.png | 1 year ago | |
| favicon.ico | 1 year ago | |
| fuwa-chan-md.png | 1 year ago | |
| index.php | 1 year ago | |
| upload-done.php | 1 year ago |
u.fuwafuwa.moe source code, stores files and deletes after X amount of time.
git clone https://git.fuwafuwa.moe/fuwafuwa/uguu.gitrain/template/footer.template.html as rain/template/footer.html and personalize the footer as you wishcrontab -e and add 0,15,30,45 * * * * cd /path/to/uguu/includes && bash check.sh (or adapt if you know how cron works).chown -R www-data:www-data /path/to/uguu/public/files and chown -R www-data:www-data /path/to/uguu/rain/cache<VirtualHost *:80>
ServerName path.to.uguu
DocumentRoot /var/www/uguu/
<Directory /var/www/uguu/>
AllowOverride All
Require all granted
</Directory>
Alias "/files" "/var/www/uguu/public/files/"
<Directory /var/www/uguu/public/files/>
<Files *>
SetHandler default-handler
</Files>
AllowOverride None
Options -Indexes
Require all granted
</Directory>
</VirtualHost>
Or something like this using Nginx+PHP-FPM:
uguu.se
server{
listen 104.243.35.197:80;
server_name uguu.se www.uguu.se;
root /home/neku/www/uguu/;
autoindex off;
index index.html index.php;
location ~* \.php$ {
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_intercept_errors on;
fastcgi_index index.php;
fastcgi_split_path_info ^(.+\.php)(.*)$;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
error_page 404 /404.html;
error_page 403 /404.html;
location /404.html {
root /home/neku/www;
}
}
a.uguu.se (notice that scripts e.g PHP will NOT be executed from this subdomain)
server{
listen 104.243.35.197:80;
server_name a.uguu.se www.a.uguu.se;
root /home/neku/www/files;
autoindex off;
index index.html;
error_page 404 /404.html;
error_page 403 /404.html;
location /404.html {
root /home/neku/www;
}
}
Leaving POST value 'randomname' empty will cause it to use original filename or custom name if 'name' is set to file.ext.
Putting anything into POST value 'randomname' will cause it to return a random filename + ext (xxxxxx.ext).
Putting a custom name into POST value 'name' will cause it to return a custom filename (yourpick.ext).
E.g: