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

Commit

Permalink
Merge pull request #78 from rtyler/master-relocate
Browse files Browse the repository at this point in the history
Relocate all the master building code into another repository
  • Loading branch information
R. Tyler Croy authored Dec 21, 2017
2 parents d021e0c + a59dc26 commit 0e8dde9
Show file tree
Hide file tree
Showing 27 changed files with 5 additions and 715 deletions.
4 changes: 0 additions & 4 deletions .dockerignore

This file was deleted.

3 changes: 0 additions & 3 deletions Dockerfile.builder

This file was deleted.

97 changes: 0 additions & 97 deletions Dockerfile.master

This file was deleted.

22 changes: 0 additions & 22 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,28 +16,6 @@ pipeline {
sh 'make generate-k8s'
}
}
stage('Create builder') {
steps {
sh 'make builder'
}
}
stage('Build necessary plugins') {
when { branch 'master' }
steps {
sh 'make plugins'
}
}
stage('Create master container') {
when { branch 'master' }
steps {
sh 'make master'
}
post {
always {
archiveArtifacts artifacts: 'build/git-refs.txt', fingerprint: true
}
}
}
stage('Test') {
steps {
sh 'make check'
Expand Down
38 changes: 4 additions & 34 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,50 +1,20 @@
IMAGE_PREFIX="rtyler/codevalet"
TF_VARFILE=.terraform.cb.json
TERRAFORM=./scripts/terraform

check: generate validate
$(MAKE) -C webapp check

all: plugins master

generate: generate-k8s agent-templates
generate: generate-k8s

run: webapp
docker-compose up

clean:
rm -f build/git-refs.txt k8/generated
rm -rf k8s/generated
docker-compose down || true
$(MAKE) -C webapp clean


## Build the Jenkins master image
###############################################################
builder: Dockerfile.builder
docker build -t ${IMAGE_PREFIX}-$@ -f Dockerfile.$@ .

master: Dockerfile.master build/git-refs.txt agent-templates
docker build -t ${IMAGE_PREFIX}-$@ -f Dockerfile.$@ .

plugins: ./scripts/build-plugins plugins.txt builder
./scripts/build-plugins

build/git-refs.txt:
./scripts/record-sha1sums
###############################################################


## Handling for agent-templates which is an external repository
###############################################################
agent-templates: build/agent-templates
(cd build/agent-templates && git pull --rebase)
docker run --rm -v $(PWD):$(PWD) -w $(PWD) ruby:2-alpine \
ruby ./scripts/render-agent-templates build/agent-templates

build/agent-templates:
git clone --depth 1 https://github.com/codevalet/agent-templates.git build/agent-templates
###############################################################


## Handle sub-projects
###############################################################
Expand Down Expand Up @@ -101,6 +71,6 @@ k8s/generated:
###############################################################


.PHONY: clean all plugins master builder plan validate \
.PHONY: clean all plan validate \
deploy generate-k8s deploy-k8s webapp check generate \
agent-templates run tfinit
run tfinit
2 changes: 0 additions & 2 deletions init.groovy.d/.gitignore

This file was deleted.

29 changes: 0 additions & 29 deletions init.groovy.d/README.adoc

This file was deleted.

17 changes: 0 additions & 17 deletions init.groovy.d/configure-datadog.groovy

This file was deleted.

9 changes: 0 additions & 9 deletions init.groovy.d/configure-quiet-period.groovy

This file was deleted.

Empty file.
6 changes: 0 additions & 6 deletions init.groovy.d/disable-cli.groovy

This file was deleted.

14 changes: 0 additions & 14 deletions init.groovy.d/enable-csrf-protection.groovy

This file was deleted.

14 changes: 0 additions & 14 deletions init.groovy.d/limit-jnlp-protocols.groovy

This file was deleted.

8 changes: 0 additions & 8 deletions init.groovy.d/limit-master-executors.groovy

This file was deleted.

34 changes: 0 additions & 34 deletions init.groovy.d/pipeline-global-configuration.groovy

This file was deleted.

9 changes: 0 additions & 9 deletions init.groovy.d/set-instance-url.groovy

This file was deleted.

Loading

0 comments on commit 0e8dde9

Please sign in to comment.