This repository has been archived by the owner on Aug 9, 2021. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
updating base image for Cross Compliation to windows and Mac.
- Loading branch information
Showing
2 changed files
with
30 additions
and
14 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,34 @@ | ||
################################################# | ||
############################################################################### | ||
# | ||
# Build Image for CapsuleCD to dogfood CapsuleCD | ||
# Should not be used for 3rd party apps | ||
# This Dockerfile should only be used to cross-compile capsulecd for various | ||
# OS's and Architectures. Its massive, and should not be used as a base image | ||
# for your Dockerfiles. | ||
# | ||
# Real Docker Images and Dockerfiles are located: | ||
# Usable Docker Images and Dockerfiles for different languages are located: | ||
# - https://github.com/AnalogJ/capsulecd-docker | ||
# - https://hub.docker.com/r/analogj/capsulecd | ||
# | ||
# Use `docker pull analogj/capsulecd:<language>` | ||
# | ||
################################################# | ||
FROM analogj/capsulecd:golang | ||
############################################################################### | ||
FROM analogj/libgit2-xgo | ||
MAINTAINER Jason Kulatunga <jason@thesparktree.com> | ||
|
||
WORKDIR /srv/capsulecd | ||
|
||
ENV PATH="/srv/capsulecd:/go/bin:${PATH}" \ | ||
SSL_CERT_FILE=/etc/ssl/certs/ca-certificates.crt | ||
|
||
RUN apt-get update && apt-get install -y --no-install-recommends \ | ||
gcc \ | ||
g++ \ | ||
pkg-config \ | ||
apt-transport-https \ | ||
ca-certificates \ | ||
git \ | ||
curl \ | ||
&& rm -rf /var/lib/apt/lists/* \ | ||
&& go get -u gopkg.in/alecthomas/gometalinter.v1 \ | ||
&& gometalinter.v1 --install \ | ||
&& go get github.com/Masterminds/glide | ||
|
||
# extract the libgit2 library here | ||
RUN cd /tmp \ | ||
&& curl -O -L https://github.com/AnalogJ/docker-libgit2-crossbuild/releases/download/v1.0.0/libgit2.static.linux-amd64.tar.gz \ | ||
&& tar xvf libgit2.static.linux-amd64.tar.gz -C /usr/local/lib/ | ||
COPY ./ci/capsulecd.sh /scripts/capsulecd.sh | ||
|
||
ENV PKG_CONFIG_PATH="/usr/lib/pkgconfig/:/usr/local/lib/pkgconfig/:/usr/local/lib/libgit2/lib/pkgconfig:/usr/local/lib/openssl/lib/pkgconfig:/usr/local/lib/libssh2" | ||
RUN /scripts/capsulecd.sh |
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,10 @@ | ||
#!/usr/bin/env bash | ||
# retrieve the latest capsulecd release info | ||
asset_url=$(curl -s https://api.github.com/repos/AnalogJ/capsulecd/releases/latest \ | ||
| grep browser_download_url | grep 'capsulecd' | cut -d '"' -f 4) | ||
|
||
# download the capsulecd asset here. | ||
curl -L -o capsulecd $asset_url | ||
|
||
# make capsulecd executable | ||
chmod +x capsulecd |