-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 9898a55
Showing
8 changed files
with
135 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
*~ | ||
.*# | ||
#* |
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,43 @@ | ||
FROM ubuntu:14.04 | ||
MAINTAINER Tomo Masakura <tomo.masakura@gmail.com> | ||
|
||
# Install packages | ||
RUN dpkg --add-architecture i386 | ||
RUN apt-get update && apt-get install -y default-jdk ant libc6:i386 libncurses5:i386 libstdc++6:i386 git build-essential curl wget zlib1g-dev libssl-dev libreadline-dev libyaml-dev libxml2-dev libxslt-dev libncurses5-dev lib32z1 lib32ncurses5 lib32bz2-1.0 lib32stdc++6 expect && apt-get clean && rm -rf /var/lib/apt/list | ||
|
||
# Install GitLab CI Multi Runner | ||
RUN curl -L https://packages.gitlab.com/install/repositories/runner/gitlab-ci-multi-runner/script.deb.sh | bash | ||
RUN apt-get install gitlab-ci-multi-runner && apt-get clean && rm -rf /var/lib/apt/list | ||
|
||
# Install rbenv & ruby-build | ||
ENV RBENV_ROOT /usr/local/.rbenv | ||
RUN git clone https://github.com/rbenv/rbenv.git ${RBENV_ROOT} && git clone https://github.com/sstephenson/ruby-build.git ${RBENV_ROOT}/plugins/ruby-build | ||
RUN echo 'PATH=${RBENV_ROOT}/bin:$PATH' >> /etc/profile | ||
RUN echo 'eval "$(rbenv init -)"' >> /etc/profile | ||
|
||
# Install Ruby | ||
ADD ./install_ruby.sh ${RBENV_ROOT}/install_ruby.sh | ||
ADD ./ruby_versions.list ${RBENV_ROOT}/ruby_versions.list | ||
ENV CONFIGURE_OPTS --disable-install-doc | ||
RUN xargs -L 1 ${RBENV_ROOT}/install_ruby.sh < ${RBENV_ROOT}/ruby_versions.list | ||
|
||
# Install nvm | ||
ENV NVM_DIR /usr/local/.nvm | ||
RUN curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.30.1/install.sh | bash | ||
#RUN echo 'source ${NVM_DIR}/nvm.sh' >> /etc/profile | ||
|
||
# Install Node.js | ||
ADD ./install_node.sh ${NVM_DIR}/install_node.sh | ||
ADD ./node_versions.list ${NVM_DIR}/node_versions.list | ||
RUN xargs -L 1 ${NVM_DIR}/install_node.sh < ${NVM_DIR}/node_versions.list | ||
|
||
# Install Android SDK | ||
ENV ANDROID_HOME /usr/local/android-sdk-linux | ||
RUN curl -L http://dl.google.com/android/android-sdk_r24.4.1-linux.tgz | tar zxvf - -C /tmp && mv /tmp/android-sdk-linux ${ANDROID_HOME} | ||
RUN echo 'PATH=$PATH:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools' >> /etc/profile | ||
ARG ANDROID_SDK_DOWNLOAD_PROXY_HOST | ||
ARG ANDROID_SDK_DOWNLOAD_PROXY_PORT | ||
ADD androidsdk_wrapper.sh ${ANDROID_HOME}/androidsdk_wrapper.sh | ||
RUN ${ANDROID_HOME}/androidsdk_wrapper.sh update sdk --no-ui --no-https --filter tools | ||
RUN ${ANDROID_HOME}/androidsdk_wrapper.sh update sdk --no-ui --no-https --all --filter build-tools-23.0.3,build-tools-22.0.1,build-tools-21.1.2,build-tools-20.0.0 | ||
RUN ${ANDROID_HOME}/androidsdk_wrapper.sh update sdk --no-ui --no-https --filter platform-tools,platform |
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,42 @@ | ||
#!/bin/bash | ||
|
||
OPTS="" | ||
LOGIN="" | ||
PASSWORD="" | ||
if [ "${http_proxy}" != "" ]; then | ||
LOGIN=`echo ${http_proxy} | sed 's/^.*:\/\///; s/:.*//;'` | ||
PASSWORD=`echo ${http_proxy} | sed 's/^[^@]*://; s/@.*//;'` | ||
fi | ||
if [ "${ANDROID_SDK_DOWNLOAD_PROXY_HOST}" != "" ]; then | ||
OPTS=" --proxy-host ${ANDROID_SDK_DOWNLOAD_PROXY_HOST} --proxy-port ${ANDROID_SDK_DOWNLOAD_PROXY_PORT}" | ||
fi | ||
|
||
CMD=`cat <<EOF | ||
spawn ${ANDROID_HOME}/tools/android $@ $OPTS | ||
set timeout 1800 | ||
expect { | ||
"Login: " { | ||
exp_send "$LOGIN\r" | ||
exp_continue | ||
} | ||
"Password: " { | ||
exp_send "$PASSWORD\r" | ||
exp_continue | ||
} | ||
"Workstation: " { | ||
exp_send "\r" | ||
exp_continue | ||
} | ||
"Domain: " { | ||
exp_send "\r" | ||
exp_continue | ||
} | ||
"Do you accept the license" { | ||
exp_send "y\r" | ||
exp_continue | ||
} | ||
} | ||
EOF | ||
` | ||
|
||
expect -c "$CMD" |
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,20 @@ | ||
machine: | ||
services: | ||
- docker | ||
|
||
dependencies: | ||
override: | ||
- docker build -t GrayBullet/docker-ci-envirnment:`git rev-parse --short HEAD` . | ||
- docker tag GrayBullet/docker-ci-envirnment:`git rev-parse --short HEAD` GrayBullet/docker-ci-envirnment | ||
|
||
test: | ||
override: | ||
- echo no test | ||
|
||
deployment: | ||
hub: | ||
branch: master | ||
commands: | ||
- docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS | ||
- docker push GrayBullet/docker-ci-envirnment:`git rev-parse --short HEAD` | ||
- docker push GrayBullet/docker-ci-envirnment |
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 @@ | ||
#!/bin/bash | ||
|
||
NODE_VERSION=$1 | ||
|
||
. $NVM_DIR/nvm.sh | ||
|
||
nvm install $NODE_VERSION | ||
nvm exec $NODE_VERSION npm install -g grunt-cli gulp bower | ||
nvm alias default $NODE_VERSION | ||
|
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 @@ | ||
#!/bin/bash -eu | ||
|
||
RUBY_VERSION=$1 | ||
|
||
PATH=${RBENV_ROOT}/bin:$PATH | ||
eval "$(rbenv init -)" | ||
|
||
rbenv install $RUBY_VERSION | ||
rbenv global $RUBY_VERSION | ||
gem install bundler --no-rdoc --no-ri | ||
|
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,3 @@ | ||
stable | ||
4 | ||
|
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,3 @@ | ||
2.0.0-p647 | ||
2.1.7 | ||
2.2.3 |