Compare commits
3 Commits
ddl
...
007416f1a9
| Author | SHA1 | Date | |
|---|---|---|---|
| 007416f1a9 | |||
| 0696c81a83 | |||
| c5f736eddf |
54
.drone.yml
Normal file
54
.drone.yml
Normal file
@@ -0,0 +1,54 @@
|
|||||||
|
kind: pipeline
|
||||||
|
name: default
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: docker_gitea
|
||||||
|
image: plugins/docker
|
||||||
|
settings:
|
||||||
|
username:
|
||||||
|
from_secret: docker_username
|
||||||
|
password:
|
||||||
|
from_secret: docker_password
|
||||||
|
repo: git.netpowa.fr/guillaume/spotdlweb
|
||||||
|
# auto_tag: true
|
||||||
|
registry: git.netpowa.fr
|
||||||
|
tags:
|
||||||
|
- latest
|
||||||
|
- v1.0.1
|
||||||
|
when:
|
||||||
|
branch: main
|
||||||
|
|
||||||
|
- name: docker_hub
|
||||||
|
image: plugins/docker
|
||||||
|
settings:
|
||||||
|
username:
|
||||||
|
from_secret: dockerhub_username
|
||||||
|
password:
|
||||||
|
from_secret: dockerhub_password
|
||||||
|
repo: gu1llaum3/spotdlweb
|
||||||
|
# auto_tag: true
|
||||||
|
tags:
|
||||||
|
- latest
|
||||||
|
- v1.0.1
|
||||||
|
when:
|
||||||
|
branch: main
|
||||||
|
|
||||||
|
- name: notify_success
|
||||||
|
image: curlimages/curl
|
||||||
|
environment:
|
||||||
|
NOTIFY_URL:
|
||||||
|
from_secret: ntfy_url
|
||||||
|
commands:
|
||||||
|
- curl -d "La pipeline a réussi" $NOTIFY_URL
|
||||||
|
when:
|
||||||
|
status: [ success ]
|
||||||
|
|
||||||
|
- name: notify_failure
|
||||||
|
image: curlimages/curl
|
||||||
|
environment:
|
||||||
|
NOTIFY_URL:
|
||||||
|
from_secret: ntfy_url
|
||||||
|
commands:
|
||||||
|
- curl -d "La pipeline a échoué" $NOTIFY_URL
|
||||||
|
when:
|
||||||
|
status: [failure]
|
||||||
Binary file not shown.
6
app.py
6
app.py
@@ -50,13 +50,11 @@ def download_file():
|
|||||||
url1 = request.form['url1']
|
url1 = request.form['url1']
|
||||||
url2 = request.form['url2']
|
url2 = request.form['url2']
|
||||||
url3 = request.form['url3']
|
url3 = request.form['url3']
|
||||||
url4 = request.form['url4']
|
|
||||||
url5 = request.form['url5']
|
|
||||||
|
|
||||||
urls = [url1, url2, url3, url4, url5]
|
urls = [url1, url2, url3]
|
||||||
|
|
||||||
# Vérifier si au moins un champ est vide
|
# Vérifier si au moins un champ est vide
|
||||||
if not url1 and not url2 and not url3 and not url4 and not url5:
|
if not url1 and not url2 and not url3 :
|
||||||
return render_template('erreur.html')
|
return render_template('erreur.html')
|
||||||
|
|
||||||
# Créer le dossier 'downloads' s'il n'existe pas
|
# Créer le dossier 'downloads' s'il n'existe pas
|
||||||
|
|||||||
@@ -32,12 +32,12 @@
|
|||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<input type="text" class="form-control" name="url3" id="url3" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
<input type="text" class="form-control" name="url3" id="url3" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<!-- <div class="form-group">
|
||||||
<input type="text" class="form-control" name="url4" id="url4" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
<input type="text" class="form-control" name="url4" id="url4" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<input type="text" class="form-control" name="url5" id="url5" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
<input type="text" class="form-control" name="url5" id="url5" pattern="^https://open\.spotify\.com/(?:album|playlist|track)/[\w-]+(?:\?si=[\w-]+)?$" placeholder="Entrez l'URL d'une Piste, d'un Album ou d'une Playlist">
|
||||||
</div>
|
</div> -->
|
||||||
<button type="submit" class="btn" id="download-button" onclick="startDownload()">Télécharger</button>
|
<button type="submit" class="btn" id="download-button" onclick="startDownload()">Télécharger</button>
|
||||||
<button type="reset" class="btn" id="refresh-button" onclick="refreshPage()">Rafraîchir</button>
|
<button type="reset" class="btn" id="refresh-button" onclick="refreshPage()">Rafraîchir</button>
|
||||||
</form>
|
</form>
|
||||||
|
|||||||
Reference in New Issue
Block a user