Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
ce11c0f6
Commit
ce11c0f6
authored
Feb 04, 2019
by
Darren Shepherd
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Get ARM CI working
parent
84756df8
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
188 additions
and
41 deletions
+188
-41
.dockerignore
.dockerignore
+2
-1
.drone.yml
.drone.yml
+175
-25
Dockerfile.dapper
Dockerfile.dapper
+1
-1
Dockerfile
package/Dockerfile
+1
-1
package-cli
scripts/package-cli
+7
-7
package-image
scripts/package-image
+2
-6
No files found.
.dockerignore
View file @
ce11c0f6
./bin
./bin
./build
./build/data
./build/data.tar.gz
./pkg/data/zz_generated_bindata.go
./pkg/data/zz_generated_bindata.go
./package/data.tar.gz
./package/data.tar.gz
./.vagrant
./.vagrant
...
...
.drone.yml
View file @
ce11c0f6
---
---
kind
:
pipeline
kind
:
pipeline
name
:
intel
name
:
amd64
platform
:
platform
:
os
:
linux
os
:
linux
arch
:
amd64
arch
:
amd64
steps
:
steps
:
-
name
:
build
-
name
:
build
privileged
:
true
image
:
rancher/dapper:v0.4.1
image
:
rancher/dapper:v0.4.0
commands
:
-
dapper ci
volumes
:
volumes
:
-
name
:
docker
-
name
:
docker
path
:
/var/run/docker.sock
path
:
/var/run/docker.sock
commands
:
-
dapper ci
-
name
:
github_binary_release
image
:
ibuildthecloud/github-release:v0.0.1
settings
:
api_key
:
from_secret
:
github_token
prerelease
:
true
checksum
:
-
sha256
checksum_file
:
CHECKSUMsum-amd64.txt
checksum_flatten
:
true
files
:
-
"
dist/artifacts/*"
when
:
instance
:
-
drone-publish.rancher.io
ref
:
-
refs/head/master
-
refs/tags/*
event
:
-
tag
-
name
:
docker-publish
image
:
plugins/docker
settings
:
dockerfile
:
package/Dockerfile
password
:
from_secret
:
docker_password
repo
:
"
ibuildthecloud/k3s"
tag
:
"
${DRONE_TAG}-amd64"
username
:
from_secret
:
docker_username
when
:
instance
:
-
drone-publish.rancher.io
ref
:
-
refs/head/master
-
refs/tags/*
event
:
-
tag
volumes
:
volumes
:
-
name
:
docker
-
name
:
docker
host
:
host
:
path
:
/var/run/docker.sock
path
:
/var/run/docker.sock
---
---
kind
:
pipeline
kind
:
pipeline
name
:
arm
name
:
arm
64
platform
:
platform
:
os
:
linux
os
:
linux
arch
:
arm64
arch
:
arm64
steps
:
steps
:
-
name
:
build
-
name
:
build
privileged
:
true
image
:
rancher/dapper:v0.4.1
image
:
rancher/dapper:v0.4.0
commands
:
environment
:
-
dapper ci
DAPPER_HOST_ARCH
:
arm
volumes
:
volumes
:
-
name
:
docker
-
name
:
docker
path
:
/var/run/docker.sock
path
:
/var/run/docker.sock
commands
:
-
dapper ci
-
name
:
github_binary_release
image
:
ibuildthecloud/github-release:v0.0.1
settings
:
api_key
:
from_secret
:
github_token
prerelease
:
true
checksum
:
-
sha256
checksum_file
:
CHECKSUMsum-arm64.txt
checksum_flatten
:
true
files
:
-
"
dist/artifacts/*"
when
:
instance
:
-
drone-publish.rancher.io
ref
:
-
refs/head/master
-
refs/tags/*
event
:
-
tag
-
name
:
docker-publish
image
:
plugins/docker
settings
:
dockerfile
:
package/Dockerfile
password
:
from_secret
:
docker_password
repo
:
"
ibuildthecloud/k3s"
tag
:
"
${DRONE_TAG}-arm64"
username
:
from_secret
:
docker_username
when
:
instance
:
-
drone-publish.rancher.io
ref
:
-
refs/head/master
-
refs/tags/*
event
:
-
tag
volumes
:
volumes
:
-
name
:
docker
-
name
:
docker
host
:
host
:
path
:
/var/run/docker.sock
path
:
/var/run/docker.sock
---
---
kind
:
pipeline
kind
:
pipeline
name
:
arm
64
name
:
arm
platform
:
platform
:
os
:
linux
os
:
linux
arch
:
arm
64
arch
:
arm
steps
:
steps
:
-
name
:
build
-
name
:
build
privileged
:
true
image
:
rancher/dapper:v0.4.1
image
:
rancher/dapper:v0.4.0
commands
:
-
dapper ci
volumes
:
volumes
:
-
name
:
docker
-
name
:
docker
path
:
/var/run/docker.sock
path
:
/var/run/docker.sock
commands
:
-
dapper ci
-
name
:
github_binary_release
image
:
ibuildthecloud/github-release:v0.0.1
settings
:
api_key
:
from_secret
:
github_token
prerelease
:
true
checksum
:
-
sha256
checksum_file
:
CHECKSUMsum-arm.txt
checksum_flatten
:
true
files
:
-
"
dist/artifacts/*"
when
:
instance
:
-
drone-publish.rancher.io
ref
:
-
refs/head/master
-
refs/tags/*
event
:
-
tag
-
name
:
docker-publish
image
:
plugins/docker
settings
:
dockerfile
:
package/Dockerfile
password
:
from_secret
:
docker_password
repo
:
"
ibuildthecloud/k3s"
tag
:
"
${DRONE_TAG}-arm"
username
:
from_secret
:
docker_username
when
:
instance
:
-
drone-publish.rancher.io
ref
:
-
refs/head/master
-
refs/tags/*
event
:
-
tag
volumes
:
volumes
:
-
name
:
docker
-
name
:
docker
host
:
host
:
path
:
/var/run/docker.sock
path
:
/var/run/docker.sock
---
kind
:
pipeline
name
:
manifest
platform
:
os
:
linux
arch
:
amd64
steps
:
-
name
:
manifest
image
:
plugins/manifest:1.0.2
settings
:
username
:
from_secret
:
docker_username
password
:
from_secret
:
docker_password
platforms
:
-
linux/amd64
-
linux/arm64
-
linux/arm
target
:
"
ibuildthecloud/k3s:${DRONE_TAG}"
template
:
"
ibuildthecloud/k3s:${DRONE_TAG}-ARCH"
when
:
instance
:
-
drone-publish.rancher.io
ref
:
-
refs/head/master
-
refs/tags/*
event
:
-
tag
depends_on
:
-
amd64
-
arm64
-
arm
Dockerfile.dapper
View file @
ce11c0f6
...
@@ -19,7 +19,7 @@ ENV ARCH $DAPPER_HOST_ARCH
...
@@ -19,7 +19,7 @@ ENV ARCH $DAPPER_HOST_ARCH
ENV DAPPER_RUN_ARGS --privileged
ENV DAPPER_RUN_ARGS --privileged
ENV DAPPER_ENV REPO TAG DRONE_TAG IMAGE_NAME
ENV DAPPER_ENV REPO TAG DRONE_TAG IMAGE_NAME
ENV DAPPER_SOURCE /go/src/github.com/rancher/k3s/
ENV DAPPER_SOURCE /go/src/github.com/rancher/k3s/
ENV DAPPER_OUTPUT ./bin ./dist
ENV DAPPER_OUTPUT ./bin ./dist
./build/out/
ENV DAPPER_DOCKER_SOCKET true
ENV DAPPER_DOCKER_SOCKET true
ENV HOME ${DAPPER_SOURCE}
ENV HOME ${DAPPER_SOURCE}
ENV CROSS true
ENV CROSS true
...
...
package/Dockerfile
View file @
ce11c0f6
FROM
alpine:3.8 as base
FROM
alpine:3.8 as base
RUN
apk add
-U
ca-certificates
RUN
apk add
-U
ca-certificates
ADD
data.tar.gz /image
ADD
build/out/
data.tar.gz /image
RUN
mkdir
-p
/image/etc/ssl/certs /image/run /image/var/run /image/tmp /image/lib/modules /image/lib/firmware
&&
\
RUN
mkdir
-p
/image/etc/ssl/certs /image/run /image/var/run /image/tmp /image/lib/modules /image/lib/firmware
&&
\
cp
/etc/ssl/certs/ca-certificates.crt /image/etc/ssl/certs/ca-certificates.crt
cp
/etc/ssl/certs/ca-certificates.crt /image/etc/ssl/certs/ca-certificates.crt
RUN
cd
image/bin
&&
\
RUN
cd
image/bin
&&
\
...
...
scripts/package-cli
View file @
ce11c0f6
...
@@ -20,13 +20,13 @@ done
...
@@ -20,13 +20,13 @@ done
rm
-rf
build/data
rm
-rf
build/data
mkdir
-p
build/data
mkdir
-p
build/data
build/out
mkdir
-p
dist
mkdir
-p
dist
/artifacts
tar
cvzf ./build/data.tar.gz
--exclude
./bin/hyperkube ./bin
tar
cvzf ./build/
out/
data.tar.gz
--exclude
./bin/hyperkube ./bin
HASH
=
$(
sha256sum
./build/data.tar.gz |
awk
'{print $1}'
)
HASH
=
$(
sha256sum
./build/
out/
data.tar.gz |
awk
'{print $1}'
)
cp
./build/data.tar.gz ./build/data/
${
HASH
}
.tgz
cp
./build/
out/
data.tar.gz ./build/data/
${
HASH
}
.tgz
BIN_SUFFIX
=
"-
${
ARCH
}
"
BIN_SUFFIX
=
"-
${
ARCH
}
"
if
[
${
ARCH
}
=
amd64
]
;
then
if
[
${
ARCH
}
=
amd64
]
;
then
...
@@ -35,8 +35,8 @@ elif [ ${ARCH} = arm ]; then
...
@@ -35,8 +35,8 @@ elif [ ${ARCH} = arm ]; then
BIN_SUFFIX
=
"-armhf"
BIN_SUFFIX
=
"-armhf"
fi
fi
cp
-f
./bin/hyperkube dist/hyperkube
${
BIN_SUFFIX
}
cp
-f
./bin/hyperkube dist/
artifacts/
hyperkube
${
BIN_SUFFIX
}
CMD_NAME
=
dist/k3s
${
BIN_SUFFIX
}
CMD_NAME
=
dist/
artifacts/
k3s
${
BIN_SUFFIX
}
go generate
go generate
LDFLAGS
=
"-X github.com/rancher/k3s/version.Version=
$VERSION
-w -s"
LDFLAGS
=
"-X github.com/rancher/k3s/version.Version=
$VERSION
-w -s"
...
...
scripts/package-image
View file @
ce11c0f6
...
@@ -3,16 +3,12 @@ set -e
...
@@ -3,16 +3,12 @@ set -e
source
$(
dirname
$0
)
/version.sh
source
$(
dirname
$0
)
/version.sh
cd
$(
dirname
$0
)
/..
/package
cd
$(
dirname
$0
)
/..
TAG
=
${
TAG
:-${
VERSION
}${
SUFFIX
}}
TAG
=
${
TAG
:-${
VERSION
}${
SUFFIX
}}
REPO
=
${
REPO
:-
rancher
}
REPO
=
${
REPO
:-
rancher
}
IMAGE_NAME
=
${
IMAGE_NAME
:-
k3s
}
IMAGE_NAME
=
${
IMAGE_NAME
:-
k3s
}
cp
-f
../build/data.tar.gz
.
IMAGE
=
${
REPO
}
/
${
IMAGE_NAME
}
:
${
TAG
}
IMAGE
=
${
REPO
}
/
${
IMAGE_NAME
}
:
${
TAG
}
docker build
-t
${
IMAGE
}
.
docker build
-t
${
IMAGE
}
-f
package/Dockerfile
.
mkdir
-p
../dist
echo
${
IMAGE
}
>
../dist/images
echo
Built
${
IMAGE
}
echo
Built
${
IMAGE
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment