Skip to content
This repository has been archived by the owner on Dec 8, 2023. It is now read-only.

Commit

Permalink
make drone happy so it will publish images
Browse files Browse the repository at this point in the history
  • Loading branch information
dweomer committed Dec 10, 2019
1 parent f45be18 commit 55e67af
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 15 deletions.
1 change: 0 additions & 1 deletion .dockerignore
Expand Up @@ -3,7 +3,6 @@
./.cache
./.trash-cache
./dist/
./build/
package/packer/vagrant/.vagrant/
package/packer/vagrant/packer_cache/
package/packer/vagrant/*.box
2 changes: 1 addition & 1 deletion Dockerfile.dapper
Expand Up @@ -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}
Expand Down
1 change: 1 addition & 0 deletions Makefile
Expand Up @@ -8,6 +8,7 @@ TARGETS := $(shell ls scripts)
@mv .dapper.tmp .dapper

$(TARGETS): .dapper
@rm -rf ./dist ./build
./.dapper $@

.DEFAULT_GOAL := default
Expand Down
6 changes: 1 addition & 5 deletions package/Dockerfile
@@ -1,7 +1,3 @@
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/
21 changes: 13 additions & 8 deletions scripts/package
Expand Up @@ -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} \
Expand All @@ -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

0 comments on commit 55e67af

Please sign in to comment.