Skip to content

Commit

Permalink
adding missing docker
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrei Neagu committed Nov 30, 2021
1 parent 6b23384 commit ab584f5
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
11 changes: 11 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,19 @@ RUN apt-get update && \
libffi-dev \
liblzma-dev \
mecab-ipadic-utf8 \
gnupg \
lsb-release \
git

# install Docker
RUN curl -fsSL https://download.docker.com/linux/ubuntu/gpg | gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg && \
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null && \
apt-get update && \
apt-get install -y docker-ce docker-ce-cli containerd.io


# Set-up necessary Env vars for PyEnv
ENV PYENV_ROOT="$HOME/.pyenv"
ENV PATH $PYENV_ROOT/shims:$PYENV_ROOT/bin:$PATH
Expand Down
11 changes: 9 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,12 @@ build: ## Builds current image
docker build -t dockerhub-service-integrationlibrary .

.PHONY: shell
shell: ## Builds current image
docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock dockerhub-service-integrationlibrary /bin/sh
shell: ## Start a shell in the built image
docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock dockerhub-service-integrationlibrary /bin/bash

.PHONY: tests
tests: ## Tests the current build
docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock dockerhub-service-integrationlibrary python --version
docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock dockerhub-service-integrationlibrary ooil --version
docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock dockerhub-service-integrationlibrary docker --version
docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock dockerhub-service-integrationlibrary docker-compose --version

0 comments on commit ab584f5

Please sign in to comment.