A correct Dockerfile usage

pull/192/head
Bruno Pinto 9 years ago
parent 391ea898d4
commit 320578df51

@ -10,16 +10,17 @@ env:
before_install:
- source tools/travis-github-pr-integration.sh
- docker build -t fish . < Dockerfile
before_script:
- docker run -e 'CI=WORKAROUND' -e "OMF_REPO_URI=$OMF_REPO_URI" -e "OMF_REPO_BRANCH=$OMF_REPO_BRANCH" -t -v $PWD:/src/oh-my-fish fish /usr/bin/fish -c "/src/oh-my-fish/bin/install"
- docker ps -a -q | xargs -i docker commit {} oh-my-fish
- docker run -t -w "/root/.local/share/omf" oh-my-fish /usr/bin/fish -c "export; tree -h"
- docker build --build-arg OMF_REPO_BRANCH=$OMF_REPO_BRANCH --build-arg OMF_REPO_URI=$OMF_REPO_URI -t oh-my-fish . < Dockerfile
- docker run -t oh-my-fish /usr/bin/fish -c "export; tree -h"
script:
- docker run -t -w "/root/.local/share/omf" oh-my-fish /usr/bin/fish "tests/test_runner.fish"
- docker run -t -w "/root/.local/share/omf" oh-my-fish /usr/bin/fish "tests/test-generate-themes-doc.fish"
- docker run -t oh-my-fish /usr/bin/fish "tests/run.fish"
- docker run -t oh-my-fish /usr/bin/fish "tests/test-generate-themes-doc.fish"
after_failure:
- docker ps -a
notifications:
email:

@ -1,11 +1,14 @@
FROM ubuntu
FROM ohmyfish/fish:2.2.0
RUN echo "Installing fish"
RUN sudo apt-get install -y software-properties-common && \
sudo apt-add-repository ppa:fish-shell/release-2 && \
sudo apt-get -y update && \
sudo apt-get -y install fish
COPY . /src/oh-my-fish
RUN echo "Installing dependencies"
RUN sudo apt-get -y install curl git tree
# Prevent install from opening a new fish shell
ENV CI WORKAROUND
# Replace this when offline installation is supported
ARG OMF_REPO_BRANCH=master
ARG OMF_REPO_URI=https://github.com/oh-my-fish/oh-my-fish
RUN fish /src/oh-my-fish/bin/install
WORKDIR /root/.local/share/omf

Loading…
Cancel
Save