drone-mella
is a drone plugin for uploading files to a OwnCloud. It is based on mella.
server
: Server URLremote_folder
: Folder inserver
where to store the filefiles
: Array of files to be compressed.tgz_name
: Suffix for the compressed file.parentdir
:true|false
. True if the directory structure should be conserved when compressing. Defaults to true.sha1sum
:true|false
. True if a hash file should be created alongside the compressed file. Defaults to truemella_username
,mella_password
: Credentials forserver
. You are advised to use environment variablesOWNCLOUD_USERNAME
andOWNCLOUD_PASSWORD
in order to hide your credentials.
pipeline:
previousaction:
[...]
deploy:
image: toroid/drone-mella
server: https://my.server.com
remote_folder: "CREATE/THIS/BEFORE"
tgz_name: latest
files:
- localFolder/*
parentdir: false
drone-mella
will put files
in a .tgz
file named after the repository: repoName_COMMIT-SHA.tgz
with COMMIT-SHA
being the last 7 characters. If a tag hook is detected, drone will set DRONE_TAG
and the file will be named: repoName_TAG.tgz
. If tgz_name
is detected, the file will be named: repoName_${tgzname}.tgz
.
Then this compressed file will be uploaded to server/remote_folder
, provided the credentials are correct and that the remote folder already exists
Don't hesitate to submit issues or pull requests.
Copyright (c)2018 by Andrés Manelli
This script comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions. See CC BY-NC-SA 4.0 for details. https://creativecommons.org/licenses/by-nc-sa/4.0/
mella is made available under the CC BY-NC-SA 4.0 license. Copyright (c) by Florian Beer