another try to get rclone working
This commit is contained in:
parent
89c8b519ee
commit
1eef94a9df
@ -6,12 +6,12 @@ steps:
|
||||
image: golang:1.14.0-alpine3.11
|
||||
pull: always
|
||||
environment:
|
||||
RCLONE_CONF:
|
||||
from_secret: rclone.conf
|
||||
FTP_PASS:
|
||||
from_secret: ftp_pass
|
||||
commands:
|
||||
- apk add --no-cache make
|
||||
- mkdir -p ~/.config/rclone
|
||||
- echo $RCLONE_CONF > ~/.config/rclone/rclone.conf
|
||||
- make rclone_config
|
||||
- cat ~/.config/rclone/rclone.conf
|
||||
- make install_deps
|
||||
- make build
|
||||
|
13
Makefile
13
Makefile
@ -1,6 +1,9 @@
|
||||
HUGO_VERSION=0.65.3
|
||||
RCLONE_VERSION=1.51.0
|
||||
OUTPUT_DIR=./public
|
||||
FTP_HOST=xsteadfastx.org
|
||||
FTP_TARGET_DIR=/
|
||||
FTP_USER=xstead_0
|
||||
|
||||
clean:
|
||||
rm -rf public
|
||||
@ -18,4 +21,12 @@ install_deps:
|
||||
ftp_upload:
|
||||
rclone sync $(OUTPUT_DIR) blog://
|
||||
|
||||
.PHONY: clean build install_deps ftp_upload
|
||||
rclone_config:
|
||||
echo "[blog]" > ~/.config/rclone/rclone.conf
|
||||
echo "type = sftp" >> ~/.config/rclone/rclone.conf
|
||||
echo "host = $(FTP_HOST)" >> ~/.config/rclone/rclone.conf
|
||||
echo "user = $(FTP_USER)" >> ~/.config/rclone/rclone.conf
|
||||
echo "pass = $(FTP_PASS)" >> ~/.config/rclone/rclone.conf
|
||||
|
||||
|
||||
.PHONY: clean build install_deps ftp_upload rclone_config
|
||||
|
Loading…
Reference in New Issue
Block a user