initial
This commit is contained in:
commit
57e838e450
25
.gitlab-ci.yml
Normal file
25
.gitlab-ci.yml
Normal file
@ -0,0 +1,25 @@
|
||||
image: docker:stable
|
||||
|
||||
stages:
|
||||
- build
|
||||
|
||||
variables:
|
||||
IMAGE_NAME: registry.gitlab.com/wolutator/docker-bash
|
||||
HUB_IMAGE_NAME: wollud1969/docker-bash-with-ldap-pam
|
||||
|
||||
build:
|
||||
stage: build
|
||||
tags:
|
||||
- hottis
|
||||
- linux
|
||||
- docker
|
||||
script:
|
||||
- VERSION=`cat VERSION`
|
||||
- docker build --tag $IMAGE_NAME:latest --tag $IMAGE_NAME:$VERSION --tag $HUB_IMAGE_NAME:$VERSION --tag $HUB_IMAGE_NAME:latest .
|
||||
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
|
||||
- docker push $IMAGE_NAME:latest
|
||||
- docker push $IMAGE_NAME:$VERSION
|
||||
- docker login -u $DOCKER_HUB_LOGIN -p $DOCKER_HUB_PASSWORD
|
||||
- docker push $HUB_IMAGE_NAME:latest
|
||||
- docker push $HUB_IMAGE_NAME:$VERSION
|
||||
|
12
Dockerfile
Normal file
12
Dockerfile
Normal file
@ -0,0 +1,12 @@
|
||||
FROM docker:stable
|
||||
|
||||
LABEL Maintainer="Wolfgang Hottgenroth <wolfgang.hottgenroth@icloud.com>"
|
||||
LABEL ImageName="registry.gitlab.com/wolutator/docker-bash"
|
||||
LABEL AlternativeImageName="wollud1969/docker-bash"
|
||||
|
||||
|
||||
RUN \
|
||||
apk add --no-cache bash
|
||||
|
||||
CMD [ "bash" ]
|
||||
|
10
readme.md
Normal file
10
readme.md
Normal file
@ -0,0 +1,10 @@
|
||||
# docker with bash
|
||||
|
||||
This is a Docker image directly derived from the Docker image `docker`, which is required whenever you need the docker tools within a container.
|
||||
|
||||
I use it regularly within Gitlab CI runners. Most recently I was wondering why a specific bash feature (variable indirection) wasn't available in a CI script. The reason was simple: the Docker `docker` image doesn't contain `bash` at all.
|
||||
|
||||
This image now is derived from the Docker `docker` image and just adds the bash.
|
||||
|
||||
I would say: Use it the same way as the original image, you just have the bash now.
|
||||
|
Loading…
x
Reference in New Issue
Block a user