Skip to content

Commit

Permalink
merged
Browse files Browse the repository at this point in the history
  • Loading branch information
olimpiurob committed Jan 19, 2024
2 parents fbefb6d + b652031 commit c86c2b9
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 58 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ RUN buildDeps="build-essential libldap2-dev libsasl2-dev libssl-dev git vim xz-u
&& mkdir /plone/instance/parts/wkhtmltopdf \
&& mv usr/local/bin/wkhtmltopdf /plone/instance/parts/wkhtmltopdf/wkhtmltopdf \
&& find /plone -not -user plone -exec chown plone:plone {} \+ \
&& gosu plone buildout -c site.cfg
&& gosu plone buildout -c site.cfg
21 changes: 5 additions & 16 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,9 @@ pipeline {
stages {


stage('Build & Test') {
when {
anyOf {
environment name: 'CHANGE_ID', value: ''
allOf {
not { environment name: 'CHANGE_ID', value: '' }
environment name: 'CHANGE_TARGET', value: 'master'
}
}
stage('Test Build & Test') {
when {
branch 'master'
}
environment {
IMAGE_NAME = BUILD_TAG.toLowerCase()
Expand All @@ -28,14 +22,9 @@ pipeline {
script {
try {
checkout scm
sh '''sed -i "s|eeacms/marine-backend|${IMAGE_NAME}|g" devel/Dockerfile'''
sh '''docker build -t ${IMAGE_NAME} .'''
sh '''docker build -t ${IMAGE_NAME}-devel devel'''
sh '''docker run -i --name=${IMAGE_NAME} -e EXCLUDE="${EXCLUDE}" -e GIT_BRANCH="${CHANGE_TARGET:-$GIT_BRANCH}" ${IMAGE_NAME}-devel /debug.sh tests'''
} finally {
sh script: "docker rm -v ${IMAGE_NAME}", returnStatus: true
sh script: "docker rmi ${IMAGE_NAME}", returnStatus: true
sh script: "docker rmi ${IMAGE_NAME}-devel", returnStatus: true
}
}
}
Expand All @@ -52,8 +41,8 @@ pipeline {
steps{
node(label: 'docker') {
script {
withCredentials([string(credentialsId: 'eea-jenkins-token', variable: 'GITHUB_TOKEN'), usernamePassword(credentialsId: 'jekinsdockerhub', usernameVariable: 'DOCKERHUB_USER', passwordVariable: 'DOCKERHUB_PASS'), string(credentialsId: 'marinebackend-devel-trigger', variable: 'TRIGGER_URL')]) {
sh '''docker pull eeacms/gitflow; docker run -i --rm --name="$BUILD_TAG" -e GIT_BRANCH="$BRANCH_NAME" -e GIT_NAME="$GIT_NAME" -e DOCKERHUB_REPO="$registry" -e GIT_TOKEN="$GITHUB_TOKEN" -e DOCKERHUB_USER="$DOCKERHUB_USER" -e DOCKERHUB_PASS="$DOCKERHUB_PASS" -e DEPENDENT_DOCKERFILE_URL="$DEPENDENT_DOCKERFILE_URL" -e TRIGGER_WAIT_FOR_LATEST="yes" -e TRIGGER_RELEASE="eeacms/marine-backend-devel;$TRIGGER_URL" -e RANCHER_CATALOG_PATHS="$template" -e GITFLOW_BEHAVIOR="RUN_ON_TAG" eeacms/gitflow'''
withCredentials([string(credentialsId: 'eea-jenkins-token', variable: 'GITHUB_TOKEN'), usernamePassword(credentialsId: 'jekinsdockerhub', usernameVariable: 'DOCKERHUB_USER', passwordVariable: 'DOCKERHUB_PASS')]) {
sh '''docker pull eeacms/gitflow; docker run -i --rm --name="$BUILD_TAG" -e GIT_BRANCH="$BRANCH_NAME" -e GIT_NAME="$GIT_NAME" -e DOCKERHUB_REPO="$registry" -e GIT_TOKEN="$GITHUB_TOKEN" -e DOCKERHUB_USER="$DOCKERHUB_USER" -e DOCKERHUB_PASS="$DOCKERHUB_PASS" -e DEPENDENT_DOCKERFILE_URL="$DEPENDENT_DOCKERFILE_URL" -e TRIGGER_RELEASE="" -e RANCHER_CATALOG_PATHS="$template" -e GITFLOW_BEHAVIOR="RUN_ON_TAG" eeacms/gitflow'''
}
}
}
Expand Down
39 changes: 0 additions & 39 deletions devel/docker-setup.sh

This file was deleted.

3 changes: 1 addition & 2 deletions site.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ eggs +=
collective.MockMailHost
collective.exportimport
eea.api.dataconnector
eea.dexterity.rdfmarshaller
eea.restapi
pdfkit
wise.theme
Expand All @@ -62,7 +61,6 @@ zcml +=
wise.theme
wise.msfd
eea.api.dataconnector
eea.dexterity.rdfmarshaller
eea.restapi

[sources]
Expand All @@ -77,6 +75,7 @@ plone.rest = 2.0.0a5
collective.z3cform.datagridfield = 1.5.3
rdflib-jsonld = 0.6.2
SQLAlchemy = 1.4.46
openpyxl = 3.0.10
# START collective.exportimport
collective.exportimport = 1.7
ijson = 3.2.0.post0
Expand Down

0 comments on commit c86c2b9

Please sign in to comment.