Skip to content

Commit

Permalink
Merge branch 'master' into alpine
Browse files Browse the repository at this point in the history
  • Loading branch information
startxfr committed May 19, 2021
2 parents b8968ec + 5679211 commit 19c509b
Show file tree
Hide file tree
Showing 44 changed files with 1,349 additions and 329 deletions.
4 changes: 4 additions & 0 deletions GitlabRunner/ansible/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,15 @@ LABEL name="$SX_ID" \
fr.startx.component="$SX_ID:$SX_VERSION"

USER root
COPY sx /tmp/
RUN apk --no-cache add \
make \
py3-pip \
ansible && \
pip install jmespath && \
mv /tmp/bin/* /bin/ && \
mv /tmp/lib/* $SX_LIBDIR/ && \
rm -rf /tmp/bin /tmp/bin && \
cd /tmp && \
wget -q https://github.com/gohugoio/hugo/releases/download/v${SX_HUGO_RELEASE}/hugo_${SX_HUGO_RELEASE}_Linux-64bit.tar.gz && \
tar xzvf hugo_${SX_HUGO_RELEASE}_Linux-64bit.tar.gz && \
Expand Down
18 changes: 18 additions & 0 deletions GitlabRunner/ansible/sx/bin/sx-runner-ansible
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/bash
source $SX_LIBDIR/sx-runner-ansible

# Dispatch input arguments
case $1 in
assemble|build) genericBuild $@ ;;
post-build) genericPostBuild $@ ;;
pre-deploy) genericPreDeploy $@ ;;
post-deploy) genericPostDeploy $@ ;;
run|start) genericRun $@ ;;
isLive|health) genericIsLive $@ ;;
isReady) genericIsReady $@ ;;
info|--info) runnerAnsibleInformation $@ ;;
usage|help|--help) genericUsage $@ ;;
usageS2i) genericUsageS2I $@ ;;
version|--version) genericVersion $@ ;;
*) genericWelcome $@ ;;
esac
10 changes: 10 additions & 0 deletions GitlabRunner/ansible/sx/lib/sx-runner-ansible
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash
source $SX_LIBDIR/sx

# Display ansible information
function runnerAnsibleInformation {
genericAllInformation $1
echoVerbose $1 "runner make : " `make --version | head -n 1`
echoVerbose $1 "ansible : " `ansible --version | head -n 1 | cut -d " " -f 2`
echoVerbose $1 "pythn : " `python --version |cut -d " " -f 2`
}
6 changes: 5 additions & 1 deletion GitlabRunner/apache/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@ LABEL name="$SX_ID" \
fr.startx.component="$SX_ID:$SX_VERSION"

USER root
RUN apk --no-cache add make
COPY sx /tmp/
RUN apk --no-cache add make && \
mv /tmp/bin/* /bin/ && \
mv /tmp/lib/* $SX_LIBDIR/ && \
rm -rf /tmp/bin /tmp/bin

USER 1001

Expand Down
19 changes: 19 additions & 0 deletions GitlabRunner/apache/sx/bin/sx-runner-apache
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/bin/bash
source $SX_LIBDIR/sx-runner-apache

check_apache_environment
# Dispatch input arguments
case $1 in
assemble|build) apacheBuild $@ ;;
post-build) apachePostBuild $@ ;;
pre-deploy) apachePreDeploy $@ ;;
post-deploy) apachePostDeploy $@ ;;
run|start) apacheRun $@ ;;
isLive|health) apacheIsLive $@ ;;
isReady) apacheIsReady $@ ;;
info|--info) runnerApacheInformation $@ ;;
usage|help|--help) genericUsage $@ ;;
usageS2i) genericUsageS2I $@ ;;
version|--version) genericVersion $@ ;;
*) genericWelcome $@ ;;
esac
8 changes: 8 additions & 0 deletions GitlabRunner/apache/sx/lib/sx-runner-apache
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash
source $SX_LIBDIR/sx-apache

# Display apache information
function runnerApacheInformation {
apacheInformation $1
echoVerbose $1 "runner make : " `make --version | head -n 1`
}
6 changes: 5 additions & 1 deletion GitlabRunner/bash/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@ LABEL name="$SX_ID" \
fr.startx.component="$SX_ID:$SX_VERSION"

USER root
RUN apk --no-cache add make
COPY sx /tmp/
RUN apk --no-cache add make && \
mv /tmp/bin/* /bin/ && \
mv /tmp/lib/* $SX_LIBDIR/ && \
rm -rf /tmp/bin /tmp/bin

USER 1001

Expand Down
18 changes: 18 additions & 0 deletions GitlabRunner/bash/sx/bin/sx-runner-bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/bash
source $SX_LIBDIR/sx-runner-bash

# Dispatch input arguments
case $1 in
assemble|build) genericBuild $@ ;;
post-build) genericPostBuild $@ ;;
pre-deploy) genericPreDeploy $@ ;;
post-deploy) genericPostDeploy $@ ;;
run|start) genericRun $@ ;;
isLive|health) genericIsLive $@ ;;
isReady) genericIsReady $@ ;;
info|--info) runnerBashInformation $@ ;;
usage|help|--help) genericUsage $@ ;;
usageS2i) genericUsageS2I $@ ;;
version|--version) genericVersion $@ ;;
*) genericWelcome $@ ;;
esac
8 changes: 8 additions & 0 deletions GitlabRunner/bash/sx/lib/sx-runner-bash
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash
source $SX_LIBDIR/sx

# Display generic information
function runnerBashInformation {
genericAllInformation $1
echoVerbose $1 "runner make : " `make --version | head -n 1`
}
6 changes: 5 additions & 1 deletion GitlabRunner/nodejs/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@ LABEL name="$SX_ID" \
fr.startx.component="$SX_ID:$SX_VERSION"

USER root
RUN apk --no-cache add make
COPY sx /tmp/
RUN apk --no-cache add make&& \
mv /tmp/bin/* /bin/ && \
mv /tmp/lib/* $SX_LIBDIR/ && \
rm -rf /tmp/bin /tmp/bin

USER 1001

Expand Down
19 changes: 19 additions & 0 deletions GitlabRunner/nodejs/sx/bin/sx-runner-nodejs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/bin/bash
source $SX_LIBDIR/sx-runner-nodejs

check_nodejs_environment
# Dispatch input arguments
case $1 in
assemble|build) nodejsBuild $@ ;;
post-build) nodejsPostBuild $@ ;;
pre-deploy) nodejsPreDeploy $@ ;;
post-deploy) nodejsPostDeploy $@ ;;
run|start) nodejsRun $@ ;;
isLive|health) nodejsIsLive $@ ;;
isReady) nodejsIsReady $@ ;;
info|--info) runnerNodejsInformation $@ ;;
usage|help|--help) genericUsage $@ ;;
usageS2i) genericUsageS2I $@ ;;
version|--version) genericVersion $@ ;;
*) genericWelcome $@ ;;
esac
8 changes: 8 additions & 0 deletions GitlabRunner/nodejs/sx/lib/sx-runner-nodejs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash
source $SX_LIBDIR/sx-nodejs

# Display nodejs information
function runnerNodejsInformation {
nodejsInformation $1
echoVerbose $1 "runner make : " `make --version | head -n 1`
}
6 changes: 5 additions & 1 deletion GitlabRunner/oc/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ LABEL name="$SX_ID" \
fr.startx.component="$SX_ID:$SX_VERSION"

USER root
COPY sx /tmp/
RUN apk --no-cache add py-pip jq && \
pip install yq && \
cd /tmp && \
Expand All @@ -31,7 +32,10 @@ RUN apk --no-cache add py-pip jq && \
tar xzvf openshift-install-linux-$SX_OC_VERSION.tar.gz && \
mv openshift-install /usr/bin/ && \
rm -f openshift-install-linux-$SX_OC_VERSION.tar.gz && \
cd -
cd - && \
mv /tmp/bin/* /bin/ && \
mv /tmp/lib/* $SX_LIBDIR/ && \
rm -rf /tmp/bin /tmp/bin

USER 1001

Expand Down
18 changes: 18 additions & 0 deletions GitlabRunner/oc/sx/bin/sx-runner-oc
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/bash
source $SX_LIBDIR/sx-runner-oc

# Dispatch input arguments
case $1 in
assemble|build) genericBuild $@ ;;
post-build) genericPostBuild $@ ;;
pre-deploy) genericPreDeploy $@ ;;
post-deploy) genericPostDeploy $@ ;;
run|start) genericRun $@ ;;
isLive|health) genericIsLive $@ ;;
isReady) genericIsReady $@ ;;
info|--info) runnerOcInformation $@ ;;
usage|help|--help) genericUsage $@ ;;
usageS2i) genericUsageS2I $@ ;;
version|--version) genericVersion $@ ;;
*) genericWelcome $@ ;;
esac
9 changes: 9 additions & 0 deletions GitlabRunner/oc/sx/lib/sx-runner-apache
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/bash
source $SX_LIBDIR/sx

# Display apache information
function runnerOcInformation {
genericAllInformation $1
echoVerbose $1 "runner oc : " `oc --version`
echoVerbose $1 "runner make : " `make --version | head -n 1`
}
6 changes: 5 additions & 1 deletion GitlabRunner/php/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@ LABEL name="$SX_ID" \
fr.startx.component="$SX_ID:$SX_VERSION"

USER root
RUN apk --no-cache add make
COPY sx /tmp/
RUN apk --no-cache add make && \
mv /tmp/bin/* /bin/ && \
mv /tmp/lib/* $SX_LIBDIR/ && \
rm -rf /tmp/bin /tmp/bin

USER 1001

Expand Down
19 changes: 19 additions & 0 deletions GitlabRunner/php/sx/bin/sx-runner-php
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/bin/bash
source $SX_LIBDIR/sx-runner-php

check_php_environment
# Dispatch input arguments
case $1 in
assemble|build) phpBuild $@ ;;
post-build) phpPostBuild $@ ;;
pre-deploy) phpPreDeploy $@ ;;
post-deploy) phpPostDeploy $@ ;;
run|start) phpRun $@ ;;
isLive|health) phpIsLive $@ ;;
isReady) phpIsReady $@ ;;
info|--info) runnerPhpInformation $@ ;;
usage|help|--help) genericUsage $@ ;;
usageS2i) genericUsageS2I $@ ;;
version|--version) genericVersion $@ ;;
*) genericWelcome $@ ;;
esac
8 changes: 8 additions & 0 deletions GitlabRunner/php/sx/lib/sx-runner-php
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash
source $SX_LIBDIR/sx-php

# Display php information
function runnerPhpInformation {
phpInformation $1
echoVerbose $1 "runner make : " `make --version | head -n 1`
}
1 change: 0 additions & 1 deletion OS/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ LABEL name="$SX_ID" \
fr.startx.component="$SX_ID:$SX_VERSION"

USER root

COPY sx /tmp/
RUN apk --no-cache update -v && apk --no-cache upgrade -v && \
apk --no-cache add -v bash pwgen tar psmisc procps findutils iputils net-tools wget logrotate zip shadow vim && \
Expand Down
25 changes: 13 additions & 12 deletions Services/couchbase/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ ENV SX_VERSION="latest" \
SX_SUMMARY="Startx couchbase service based on fedora rawhide" \
CB_PATH=/opt/couchbase \
DATA_PATH=/opt/couchbase/var \
CB_VERSION=6.0.2 \
CB_RELEASE_URL=https://packages.couchbase.com/releases/6.0.2 \
CB_PACKAGE=couchbase-server-enterprise-6.0.2-rhel8.x86_64.rpm \
CB_VERSION=6.6.2 \
CB_RELEASE_URL=https://packages.couchbase.com/releases/6.6.2 \
CB_PACKAGE=couchbase-server-enterprise-6.6.2-centos8.x86_64.rpm \
PATH=$PATH:/opt/couchbase/bin:/opt/couchbase/bin/tools:/opt/couchbase/bin/install

LABEL name="$SX_ID" \
Expand All @@ -33,15 +33,16 @@ LABEL name="$SX_ID" \

USER root
COPY sx /tmp/
RUN dnf install -yq yum-utils dnf-plugin-system-upgrade && \
dnf upgrade -yq --refresh && \
RUN dnf install -yq --nogpgcheck yum-utils dnf-plugin-system-upgrade && \
dnf upgrade -yq --nogpgcheck --refresh && \
dnf install -yq --nogpgcheck \
python2-httplib2 \
openssl \
ncurses \
ncurses-libs \
ncurses-compat-libs \
python2 && \
python3-httplib2 \
openssl \
ncurses \
ncurses-libs \
ncurses-compat-libs \
python3 \
bzip2 && \
package-cleanup --problems && \
package-cleanup --orphans && \
dnf remove -yq --skip-broken dnf-plugin-system-upgrade yum-utils yum && \
Expand Down Expand Up @@ -81,7 +82,7 @@ USER 1001

WORKDIR $DATA_PATH

EXPOSE 8091 8092 8093 8094 11207 11210 11211 18091 18092 18093 18094
EXPOSE 8091-8096 11207-11211 18091-18096 9100-9140 19130 21100-21300 9998-9999

VOLUME $DATA_PATH

Expand Down
19 changes: 10 additions & 9 deletions Services/ooconv/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,16 @@ LABEL name="$SX_ID" \

USER root
COPY sx /tmp/
RUN dnf install -yq yum-utils dnf-plugin-system-upgrade && \
dnf upgrade -yq --refresh && \
dnf install -yq --nogpgcheck \
unoconv \
libreoffice-writer \
libreoffice-calc \
pdfmod \
ghostscript && \
package-cleanup --problems && \
RUN dnf install -yq --nogpgcheck yum-utils dnf-plugin-system-upgrade && \
dnf upgrade -yq --nogpgcheck --refresh
RUN dnf install -yq --nogpgcheck \
unoconv \
libreoffice-writer \
libreoffice-calc \
libreoffice-postgresql \
pdfmod \
ghostscript
RUN package-cleanup --problems && \
package-cleanup --orphans && \
dnf remove -yq --skip-broken dnf-plugin-system-upgrade yum-utils yum && \
dnf clean all --enablerepo=\* && \
Expand Down
2 changes: 1 addition & 1 deletion Services/php/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,6 @@ WORKDIR $APP_PATH

EXPOSE $APP_PORT

VOLUME [ $SX_PHPSESS_PATH ]
VOLUME $SX_PHPSESS_PATH

CMD [ "/bin/sx-php" , "run" ]
30 changes: 16 additions & 14 deletions docs/GitlabRunner/ansible.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,22 @@ based on [startx/fedora container](https://hub.docker.com/r/startx/fedora)

## Available flavours

- `:latest` : Fedora core rawhide + ansible + make
- `:fc34` : Fedora core 34 + ansible + make
- `:fc33` : Fedora core 33 + ansible + make
- `:fc32` : Fedora core 32 + ansible + make
- `:fc31` : Fedora core 31 + ansible + make
- `:fc30` : Fedora core 30 + ansible + make
- `:fc29` : Fedora core 29 + ansible + make
- `:fc28` : Fedora core 28 + ansible + make
- `:fc27` : Fedora core 27 + ansible + make
- `:centos8` : CentOS 8 + ansible + make
- `:centos7` : CentOS 7 + ansible + make
- `:centos6` : Centos 6 + ansible + make
- `:alpine3` : Alpine 3.12 + ansible + make
- `:ubi8` : RedHat UBI 8 + ansible + make
| Docker Hub repository | Content | Ansible | Python | Make |
| --------------------------------------------------------------------------------- | ------------------- | ------- | ------ | ---- |
| [`startx/runner-ansible:latest`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core rawhide | | | 4.3 |
| [`startx/runner-ansible:34`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core 34 | | | 4.3 |
| [`startx/runner-ansible:33`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core 33 | | | 4.3 |
| [`startx/runner-ansible:32`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core 32 | | | |
| [`startx/runner-ansible:31`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core 31 | | | |
| [`startx/runner-ansible:30`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core 30 | | | |
| [`startx/runner-ansible:29`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core 29 | | | |
| [`startx/runner-ansible:28`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core 28 | | | |
| [`startx/runner-ansible:27`](https://hub.docker.com/r/startx/runner-ansible) | Fedora core 27 | | | |
| [`startx/runner-ansible:centos8`](https://hub.docker.com/r/startx/runner-ansible) | Centos 8 | | | |
| [`startx/runner-ansible:centos7`](https://hub.docker.com/r/startx/runner-ansible) | Centos 7 | | | |
| [`startx/runner-ansible:centos6`](https://hub.docker.com/r/startx/runner-ansible) | Centos 6 | | | |
| [`startx/runner-ansible:ubi8`](https://hub.docker.com/r/startx/runner-ansible) | RedHat UBI 8 | | | |
| [`startx/runner-ansible:alpine3`](https://hub.docker.com/r/startx/runner-ansible) | Alpine 3.12 | | | |

## Running from dockerhub registry

Expand Down

0 comments on commit 19c509b

Please sign in to comment.