From e5f6afdc2853c2bbfe49d1d3db8bacac3949d375 Mon Sep 17 00:00:00 2001 From: Danny Bessems Date: Wed, 27 Jul 2022 10:39:59 +0200 Subject: [PATCH] Add build step --- .drone.yml | 50 ++++++++++++++++++++++---------------------------- 1 file changed, 22 insertions(+), 28 deletions(-) diff --git a/.drone.yml b/.drone.yml index 372838d..136abea 100644 --- a/.drone.yml +++ b/.drone.yml @@ -6,37 +6,31 @@ volumes: - name: output claim: name: flexvolsmb-drone-output -# - name: scratch -# temp: {} +- name: scratch + temp: {} steps: - name: Clone skopeo source repository image: bv11-cr01.bessems.eu/proxy/alpine/git commands: - - pwd - - git clone https://github.com/containers/skopeo.git ./skopeo - - ls . -lash + - git clone https://github.com/containers/skopeo.git /tmp/skopeo && cd /tmp/skopeo - git checkout tags/v1.9.1 - # volumes: - # - name: scratch - # path: /tmp - -# - name: Remove temporary resources -# image: bv11-cr01.bessems.eu/library/packer-extended -# commands: -# - | -# pwsh -file scripts/Remove-Resources.ps1 \ -# -VMName $DRONE_BUILD_NUMBER-${DRONE_COMMIT_SHA:0:10} \ -# -VSphereFQDN 'bv11-vc.bessems.lan' \ -# -VSphereUsername 'administrator@vsphere.local' \ -# -VSpherePassword $${VSPHERE_PASSWORD} -# environment: -# VSPHERE_PASSWORD: -# from_secret: vsphere_password -# volumes: -# - name: scratch -# path: /scratch -# when: -# status: -# - success -# - failure + volumes: + - name: scratch + path: /tmp +- name: Build binary + image: bv11-cr01.bessems.eu/proxy/library/golang + commands: + - apt-get update && apt-get install -y go-md2man + - | + make \ + -C /tmp/skopeo + BUILDTAGS=containers_image_openpgp \ + GO_DYN_FLAGS= + - /tmp/skopeo/bin/skopeo --version + # - cp /tmp/skopeo/bin/skopeo /output + environment: + CGO_ENABLED: 0 + volumes: + - name: output + path: /output