Unverified Commit f054b945 authored by Jacob Blain Christen's avatar Jacob Blain Christen Committed by GitHub
Browse files

Merge pull request #325 from dweomer/package/docker-fix

make drone happy so it will publish images
parents f45be187 55e67afa
No related merge requests found
Showing with 16 additions and 15 deletions
+16 -15
......@@ -3,7 +3,6 @@
./.cache
./.trash-cache
./dist/
./build/
package/packer/vagrant/.vagrant/
package/packer/vagrant/packer_cache/
package/packer/vagrant/*.box
......@@ -19,7 +19,7 @@ RUN go get -d github.com/rancher/trash && \
ENV DAPPER_ENV REPO TAG DRONE_TAG
ENV DAPPER_SOURCE /go/src/github.com/rancher/k3os/
ENV DAPPER_OUTPUT ./dist
ENV DAPPER_OUTPUT ./build ./dist
ENV DAPPER_DOCKER_SOCKET true
ENV TRASH_CACHE ${DAPPER_SOURCE}/.trash-cache
ENV HOME ${DAPPER_SOURCE}
......
......@@ -8,6 +8,7 @@ TARGETS := $(shell ls scripts)
@mv .dapper.tmp .dapper
$(TARGETS): .dapper
@rm -rf ./dist ./build
./.dapper $@
.DEFAULT_GOAL := default
......
ARG TAG
ARG REPO
FROM ${REPO}/k3os-package:${TAG} AS package
FROM scratch
ENV PATH /k3os/system/k3os/current:/k3os/system/k3s/current
COPY --from=package /output/k3os/system/ /k3os/system/
COPY build/k3os/system/ /k3os/system/
......@@ -6,6 +6,19 @@ source $(dirname $0)/images
cd $(dirname $0)/..
DIST=$(pwd)/dist/artifacts
pushd images/output
build_all "$@"
mkdir -p ${DIST}
copy_all ${DIST} "$@"
popd
mkdir -p ./build
ID=$(docker create ${REPO}/k3os-package:${TAG})
docker cp ${ID}:/output/k3os ./build/
docker rm -fv $ID
docker build \
--build-arg ARCH=${ARCH} \
--build-arg REPO=${REPO} \
......@@ -14,11 +27,3 @@ docker build \
--file package/Dockerfile \
--tag ${REPO}/k3os:${TAG} \
.
DIST=$(pwd)/dist/artifacts
pushd images/output
build_all "$@"
mkdir -p ${DIST}
copy_all ${DIST} "$@"
popd
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment