This repository has been archived by the owner on Oct 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 137
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from mesosphere/add-docker-image
Add docker image
- Loading branch information
Showing
10 changed files
with
97 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
FROM centos:centos7 | ||
MAINTAINER Mesosphere Package Builder <[email protected]> | ||
|
||
RUN yum -y update && \ | ||
yum -y install epel-release && \ | ||
yum -y group install 'Development Tools' && \ | ||
yum -y install golang && \ | ||
yum clean all | ||
|
||
RUN mkdir -p /build/ && \ | ||
mkdir -p /package/root/ && \ | ||
mkdir -p /package/root/etc/ && \ | ||
mkdir -p /package/root/usr/bin/ | ||
|
||
RUN cd /package/root/etc/ && ln -s /proc/mounts mtab | ||
|
||
COPY etc/group /package/root/etc/ | ||
COPY etc/hostname /package/root/etc/ | ||
COPY etc/hosts /package/root/etc/ | ||
COPY etc/nsswitch.conf /package/root/etc/ | ||
COPY etc/passwd /package/root/etc/ | ||
COPY etc/resolv.conf /package/root/etc/ | ||
|
||
COPY bap.sh /usr/bin/bap | ||
|
||
CMD ["bap"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
#!/bin/sh | ||
if [ ! -d /target ] | ||
then | ||
echo "output directory /target not found" | ||
exit 1 | ||
fi | ||
mkdir -p /build/ | ||
mkdir -p /package/root/ | ||
mkdir -p /package/root/usr/bin/ | ||
mkdir -p /package/root/lib64/ | ||
export GOPATH=/build | ||
go get github.com/miekg/dns | ||
go get github.com/mesosphere/mesos-dns | ||
cd $GOPATH/src/github.com/mesosphere/mesos-dns | ||
go build -o mesos-dns | ||
strip mesos-dns | ||
cp mesos-dns /package/root/usr/bin/ | ||
cp /lib64/ld-linux-x86-64.so.2 /package/root/lib64/ | ||
cp /lib64/libc.so.6 /package/root/lib64/ | ||
cp /lib64/libnss_compat.so.2 /package/root/lib64/ | ||
cp /lib64/libnss_dns.so.2 /package/root/lib64/ | ||
cp /lib64/libnss_files.so.2 /package/root/lib64/ | ||
cp /lib64/libpthread.so.0 /package/root/lib64/ | ||
cd /package/root | ||
tar czvf ../mesos-dns_rootfs.tar.gz . | ||
cd .. | ||
cp mesos-dns_rootfs.tar.gz /target/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
root:x:0: | ||
bin:x:1: | ||
daemon:x:2: | ||
adm:x:4: | ||
lp:x:7: | ||
mail:x:12: | ||
games:x:20: | ||
ftp:x:50: | ||
nobody:x:99: | ||
users:x:100: | ||
nfsnobody:x:65534: |
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
passwd: files | ||
shadow: files | ||
group: files | ||
hosts: files dns |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
root:x:0:0:root:/root:/bin/bash | ||
bin:x:1:1:bin:/bin:/sbin/nologin | ||
daemon:x:2:2:daemon:/sbin:/sbin/nologin | ||
adm:x:3:4:adm:/var/adm:/sbin/nologin | ||
lp:x:4:7:lp:/var/spool/lpd:/sbin/nologin | ||
sync:x:5:0:sync:/sbin:/bin/sync | ||
shutdown:x:6:0:shutdown:/sbin:/sbin/shutdown | ||
halt:x:7:0:halt:/sbin:/sbin/halt | ||
mail:x:8:12:mail:/var/spool/mail:/sbin/nologin | ||
operator:x:11:0:operator:/root:/sbin/nologin | ||
games:x:12:100:games:/usr/games:/sbin/nologin | ||
ftp:x:14:50:FTP User:/var/ftp:/sbin/nologin | ||
nobody:x:99:99:Nobody:/:/sbin/nologin |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
FROM scratch | ||
MAINTAINER Mesosphere Package Builder <[email protected]> | ||
ADD mesos-dns_rootfs.tar.gz / | ||
|
||
CMD ["/usr/bin/mesos-dns"] |