11 Commits

Author SHA1 Message Date
arian 9922467cb6 chore(deps): update Dropzone.js upstream source
Build Debian Package / build (push) Successful in 8s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-28 21:51:18 -04:00
arian 8e105d8b93 Merge branch 'actions'
Build Debian Package / build (push) Successful in 6s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-28 19:32:00 -04:00
arian 5acd4ac728 ci(build): add branch and tag triggers for build workflow
Build Debian Package / build (push) Successful in 7s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-28 19:29:41 -04:00
arian 387c139274 Merge branch 'pr-templates-rm'
Build Debian Package / build (push) Successful in 8s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-27 18:13:10 -04:00
arian 95556d4d84 refactor(upload): remove unused templates
Build Debian Package / build (push) Successful in 9s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-27 18:05:06 -04:00
arian a56203f4f5 Merge branch 'actions'
Build Debian Package / build (push) Successful in 6s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-27 17:44:47 -04:00
arian 67e9ba55bf ci(debian): downgrade upload-artifact action to v3
Build Debian Package / build (push) Successful in 17s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-27 00:47:09 -04:00
arian 62d70d4726 ci(docker): update build script to copy output from container
Build Debian Package / build (push) Failing after 8s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-27 00:45:12 -04:00
arian fc162bc6ee Revert "ci(debian): fix permissions issue with deb building workflow"
Build Debian Package / build (push) Successful in 8s
This reverts commit 053be5dbe5.

Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-27 00:41:31 -04:00
arian 053be5dbe5 ci(debian): fix permissions issue with deb building workflow
Build Debian Package / build (push) Successful in 8s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-27 00:34:46 -04:00
arian 310ebfe903 ci(debian): add gitea workflow for automated deb package building
Build Debian Package / build (push) Successful in 1m28s
Signed-off-by: Arian Nasr <arian@2ari.ca>
2026-05-27 00:21:46 -04:00
10 changed files with 59 additions and 46 deletions
+31
View File
@@ -0,0 +1,31 @@
name: Build Debian Package
on:
push:
branches:
- '**'
tags:
- 'v*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Make scripts executable
run: |
chmod +x release/build-docker.sh
chmod +x release/build-deb.sh
- name: Build Debian Package
run: ./release/build-docker.sh
- name: Upload Build Artifact
uses: actions/upload-artifact@v3
with:
name: navidrome-uploader-deb
path: output/*.deb
retention-days: 5
+5 -3
View File
@@ -3,7 +3,7 @@
# March 6, 2026
import os
from flask import Flask, request, render_template
from flask import Flask, request, render_template, jsonify
from werkzeug.utils import secure_filename
UPLOAD_FOLDER = os.environ.get('NAVIDROME_MUSIC_FOLDER', '/opt/navidrome/music')
@@ -25,13 +25,15 @@ def ping():
@app.route('/', methods=['GET', 'POST'])
def upload_file():
if request.method == 'POST':
uploaded_count = 0
for key, file in request.files.items():
if key.startswith('file') and file and allowed_file(file.filename) and file.filename != '':
filename = secure_filename(file.filename)
file.save(os.path.join(app.config['UPLOAD_FOLDER'], filename))
uploaded_count += 1
else:
return render_template('error.html', error_message=f'File is not allowed.'), 400
return jsonify({"error": f"File '{file.filename}' is not allowed or is empty."}), 400
return render_template('success.html', success_message=f'{len(request.files)} file(s) uploaded successfully!'), 200
return jsonify({"message": f"{uploaded_count} file(s) uploaded successfully!"}), 200
return render_template('index.html'), 200
+5 -1
View File
@@ -8,4 +8,8 @@ cd "${PROJECT_ROOT}"
docker build --platform linux/amd64 -t uploader-builder -f Dockerfile.build .
docker run --rm --platform linux/amd64 -v "$(pwd)/output:/dist" uploader-builder
docker run --name uploader-builder-container --platform linux/amd64 uploader-builder
docker cp uploader-builder-container:/dist/. output/
docker rm uploader-builder-container
+1
View File
@@ -0,0 +1 @@
@keyframes passing-through{0%{opacity:0;transform:translateY(40px)}30%,70%{opacity:1;transform:translateY(0px)}100%{opacity:0;transform:translateY(-40px)}}@keyframes slide-in{0%{opacity:0;transform:translateY(40px)}30%{opacity:1;transform:translateY(0px)}}@keyframes pulse{0%{transform:scale(1)}10%{transform:scale(1.1)}20%{transform:scale(1)}}.dropzone,.dropzone *{box-sizing:border-box}.dropzone{min-height:150px;border:1px solid rgba(0,0,0,.8);border-radius:5px;padding:20px 20px}.dropzone.dz-clickable{cursor:pointer}.dropzone.dz-clickable *{cursor:default}.dropzone.dz-clickable .dz-message,.dropzone.dz-clickable .dz-message *{cursor:pointer}.dropzone.dz-started .dz-message{display:none}.dropzone.dz-drag-hover{border-style:solid}.dropzone.dz-drag-hover .dz-message{opacity:.5}.dropzone .dz-message{text-align:center;margin:3em 0}.dropzone .dz-message .dz-button{background:none;color:inherit;border:none;padding:0;font:inherit;cursor:pointer;outline:inherit}.dropzone .dz-preview{position:relative;display:inline-block;vertical-align:top;margin:16px;min-height:100px}.dropzone .dz-preview:hover{z-index:1000}.dropzone .dz-preview:hover .dz-details{opacity:1}.dropzone .dz-preview.dz-file-preview .dz-image{border-radius:20px;background:#999;background:linear-gradient(to bottom, #eee, #ddd)}.dropzone .dz-preview.dz-file-preview .dz-details{opacity:1}.dropzone .dz-preview.dz-image-preview{background:#fff}.dropzone .dz-preview.dz-image-preview .dz-details{transition:opacity .2s linear}.dropzone .dz-preview .dz-remove{font-size:14px;text-align:center;display:block;cursor:pointer;border:none}.dropzone .dz-preview .dz-remove:hover{text-decoration:underline}.dropzone .dz-preview:hover .dz-details{opacity:1}.dropzone .dz-preview .dz-details{z-index:20;position:absolute;top:0;left:0;opacity:0;font-size:13px;min-width:100%;max-width:100%;padding:2em 1em;text-align:center;color:rgba(0,0,0,.9);line-height:150%}.dropzone .dz-preview .dz-details .dz-size{margin-bottom:1em;font-size:16px}.dropzone .dz-preview .dz-details .dz-filename{white-space:nowrap}.dropzone .dz-preview .dz-details .dz-filename:hover span{border:1px solid rgba(200,200,200,.8);background-color:hsla(0,0%,100%,.8)}.dropzone .dz-preview .dz-details .dz-filename:not(:hover){overflow:hidden;text-overflow:ellipsis}.dropzone .dz-preview .dz-details .dz-filename:not(:hover) span{border:1px solid rgba(0,0,0,0)}.dropzone .dz-preview .dz-details .dz-filename span,.dropzone .dz-preview .dz-details .dz-size span{background-color:hsla(0,0%,100%,.4);padding:0 .4em;border-radius:3px}.dropzone .dz-preview:hover .dz-image img{transform:scale(1.05, 1.05);filter:blur(8px)}.dropzone .dz-preview .dz-image{border-radius:20px;overflow:hidden;width:120px;height:120px;position:relative;display:block;z-index:10}.dropzone .dz-preview .dz-image img{display:block}.dropzone .dz-preview.dz-success .dz-success-mark{animation:passing-through 3s cubic-bezier(0.77, 0, 0.175, 1)}.dropzone .dz-preview.dz-error .dz-error-mark{opacity:1;animation:slide-in 3s cubic-bezier(0.77, 0, 0.175, 1)}.dropzone .dz-preview .dz-success-mark,.dropzone .dz-preview .dz-error-mark{pointer-events:none;opacity:0;z-index:500;position:absolute;display:block;top:50%;left:50%;margin-left:-27px;margin-top:-27px;background:rgba(0,0,0,.8);border-radius:50%}.dropzone .dz-preview .dz-success-mark svg,.dropzone .dz-preview .dz-error-mark svg{display:block;width:54px;height:54px;fill:#fff}.dropzone .dz-preview.dz-processing .dz-progress{opacity:1;transition:all .2s linear}.dropzone .dz-preview.dz-complete .dz-progress{opacity:0;transition:opacity .4s ease-in}.dropzone .dz-preview:not(.dz-processing) .dz-progress{animation:pulse 6s ease infinite}.dropzone .dz-preview .dz-progress{opacity:1;z-index:1000;pointer-events:none;position:absolute;height:20px;top:50%;margin-top:-10px;left:15%;right:15%;border:3px solid rgba(0,0,0,.8);background:rgba(0,0,0,.8);border-radius:10px;overflow:hidden}.dropzone .dz-preview .dz-progress .dz-upload{background:#fff;display:block;position:relative;height:100%;width:0;transition:width 300ms ease-in-out;border-radius:17px}.dropzone .dz-preview.dz-error .dz-error-message{display:block}.dropzone .dz-preview.dz-error:hover .dz-error-message{opacity:1;pointer-events:auto}.dropzone .dz-preview .dz-error-message{pointer-events:none;z-index:1000;position:absolute;display:block;display:none;opacity:0;transition:opacity .3s ease;border-radius:8px;font-size:13px;top:130px;left:-10px;width:140px;background:#b10606;padding:.5em 1em;color:#fff}.dropzone .dz-preview .dz-error-message:after{content:"";position:absolute;top:-6px;left:64px;width:0;height:0;border-left:6px solid rgba(0,0,0,0);border-right:6px solid rgba(0,0,0,0);border-bottom:6px solid #b10606}/*# sourceMappingURL=dropzone.css.map */
-1
View File
File diff suppressed because one or more lines are too long
+2
View File
File diff suppressed because one or more lines are too long
-1
View File
File diff suppressed because one or more lines are too long
-14
View File
@@ -1,14 +0,0 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Error - Upload Music</title>
<link rel="stylesheet" href="{{ url_for('static', filename='css/style.css') }}" type="text/css" />
</head>
<body>
<h1>Error</h1>
<p>{{ error_message }}</p>
<a href="/"><button>Upload another file</button></a>
</body>
</html>
+15 -12
View File
@@ -5,19 +5,22 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Upload Music</title>
<link rel="stylesheet" href="{{ url_for('static', filename='css/style.css') }}" type="text/css" />
<script src="{{ url_for('static', filename='js/dropzone.min.js') }}"></script>
<link rel="stylesheet" href="{{ url_for('static', filename='css/dropzone.min.css') }}" type="text/css" />
<link rel="stylesheet" href="{{ url_for('static', filename='css/dropzone.css') }}" type="text/css" />
</head>
<body>
<script>
Dropzone.options.myDropzone = {
parallelUploads: 4,
uploadMultiple: true,
acceptedFiles: 'audio/*'
};
</script>
<form action="/"
class="dropzone"
id="my-dropzone"></form>
<form action="/"
class="dropzone"
id="my-dropzone"
enctype="multipart/form-data"></form>
<script src="{{ url_for('static', filename='js/dropzone-min.js') }}"></script>
<script>
const dz = new Dropzone("#my-dropzone", {
url: "/",
parallelUploads: 4,
uploadMultiple: true,
acceptedFiles: "audio/*"
});
</script>
</body>
</html>
-14
View File
@@ -1,14 +0,0 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Success - Upload Music</title>
<link rel="stylesheet" href="{{ url_for('static', filename='css/style.css') }}" type="text/css" />
</head>
<body>
<h1>Success</h1>
<p>{{ success_message }}</p>
<a href="/"><button>Upload another file</button></a>
</body>
</html>