Skip to content
This repository has been archived by the owner on Jan 19, 2024. It is now read-only.

Commit

Permalink
Ready to deploy from master branch (#3)
Browse files Browse the repository at this point in the history
* StatusType.volgnummer toegevoegd t.b.v. VNG-Realisatie#153

* Update API spec n.a.v. API aanpassingen

* Ref. VNG-Realisatie/gemma-zaken#130 -- mogelijke foutantwoorden in OAS

* DSO API-50 tests toegevoegd

* Ref. VNG-Realisatie/gemma-zaken#162 -- clean up BesluitType data model

* Ref. VNG-Realisatie/gemma-zaken#162 -- voeg besluittype toe aan API

* US-162 -- fix tests

* Besluittype tests

* Correcte MIME-types voor error responses

* Fix incorrect content-type

* Set up contrib.sites

* Bump zds-schema version

* Logisch attribuut "isEindstatus" toegevoegd aan StatusType t.b.v. US 351.

* Publicatietekst & toelichting hebben geen lengte-limitatie

Zie: https://github.com/VNG-Realisatie/gemma-zaken/pull/362\#pullrequestreview-168803832

* added initial jenkinsfile

* removed AS production form the last docker phase

* jenkinsfile with new phases

* trigger for branch develop

* fix typo (#1)

* Features/bas 1271 (#2)

* fix typo

* trigger on master branch
  • Loading branch information
sercanyaldiz authored Nov 13, 2018
1 parent 03a4cc7 commit 2118e8f
Show file tree
Hide file tree
Showing 51 changed files with 3,566 additions and 1,055 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ CMD ["/runtests.sh"]


# Stage 4 - Build docker image suitable for execution and deployment
FROM python:3.6-alpine AS production
FROM python:3.6-alpine
RUN apk --no-cache add \
ca-certificates \
mailcap \
Expand Down
91 changes: 91 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
def tryStep(String message, Closure block, Closure tearDown = null) {
try {
block()
}
catch (Throwable t) {
// slackSend message: "${env.JOB_NAME}: ${message} failure ${env.BUILD_URL}", channel: '#ci-channel-app', color: 'danger'

throw t
}
finally {
if (tearDown) {
tearDown()
}
}
}


node {
stage("Checkout") {
checkout scm
}



stage("Build image") {
tryStep "build", {
def image = docker.build("build.datapunt.amsterdam.nl:5000/gemma-ztc:${env.BUILD_NUMBER}")
image.push()

}
}
}



String BRANCH = "${env.BRANCH_NAME}"

if (BRANCH == "master") {

node {
stage('Push acceptance image') {
tryStep "image tagging", {
def image = docker.image("build.datapunt.amsterdam.nl:5000/gemma-ztc:${env.BUILD_NUMBER}")
image.pull()
image.push("acceptance")
image.push("production")
}
}
}

node {
stage("Deploy to ACC") {
tryStep "deployment", {
build job: 'Subtask_Openstack_Playbook',
parameters: [
[$class: 'StringParameterValue', name: 'INVENTORY', value: 'acceptance'],
[$class: 'StringParameterValue', name: 'PLAYBOOK', value: 'deploy-zaaktypecatalogus.yml'],
]
}
}
}


stage('Waiting for approval') {
slackSend channel: '#ci-channel-app', color: 'warning', message: 'zaaktypecatalogus is waiting for Production Release - please confirm'
input "Deploy to Production?"
}

node {
stage('Push production image') {
tryStep "image tagging", {
def image = docker.image("build.datapunt.amsterdam.nl:5000/gemma-ztc:${env.BUILD_NUMBER}")
image.pull()
image.push("production")
image.push("latest")
}
}
}

node {
stage("Deploy") {
tryStep "deployment", {
build job: 'Subtask_Openstack_Playbook',
parameters: [
[$class: 'StringParameterValue', name: 'INVENTORY', value: 'production'],
[$class: 'StringParameterValue', name: 'PLAYBOOK', value: 'deploy-zaaktypecatalogus.yml'],
]
}
}
}
}
Loading

0 comments on commit 2118e8f

Please sign in to comment.