This commit is contained in:
9
.drone.sh
Normal file
9
.drone.sh
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
export now=$(TZ=Australia/Sydney date '+%Y%m%d-%H%M%S')
|
||||||
|
echo $now
|
||||||
|
echo "build commences"
|
||||||
|
go build -ldflags "-X main.sha1ver=`git rev-parse HEAD` -X main.buildTime=$now" -o ntpcheck
|
||||||
|
echo "build complete"
|
||||||
|
sha256sum ntpcheck > ntpcheck_checksum.txt
|
||||||
|
ls -lah
|
29
.drone.yml
Normal file
29
.drone.yml
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
kind: pipeline
|
||||||
|
type: docker
|
||||||
|
name: default
|
||||||
|
|
||||||
|
# Docs at https://docs.drone.io/pipeline/exec/overview/
|
||||||
|
# Also see https://github.com/harness/drone-cli/blob/master/.drone.yml
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: build
|
||||||
|
image: golang
|
||||||
|
commands:
|
||||||
|
- sh ./.drone.sh
|
||||||
|
|
||||||
|
# https://github.com/hypervtechnics/drone-sftp
|
||||||
|
- name: dell-sftp-deploy
|
||||||
|
image: hypervtechnics/drone-sftp
|
||||||
|
settings:
|
||||||
|
host: deft.dell.com
|
||||||
|
username:
|
||||||
|
from_secret: DELLFTP_USER
|
||||||
|
password:
|
||||||
|
from_secret: DELLFTP_PASS
|
||||||
|
port: 22
|
||||||
|
source: ./
|
||||||
|
filter: ntpcheck*
|
||||||
|
clean: false
|
||||||
|
target: /
|
||||||
|
overwrite: true
|
||||||
|
verbose: true
|
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
log.txt
|
||||||
|
ntpcheck*
|
Reference in New Issue
Block a user