Initial euclide.org release
This commit is contained in:
46
Makefile.ci
Normal file
46
Makefile.ci
Normal file
@@ -0,0 +1,46 @@
|
||||
# -*- mode: makefile -*-
|
||||
SHELL := /bin/sh
|
||||
PROJECTNAME := pdns-auth-proxy
|
||||
VERSION := $(shell git rev-parse --short HEAD)
|
||||
TO := _
|
||||
|
||||
ifdef BUILD_NUMBER
|
||||
NUMBER = $(BUILD_NUMBER)
|
||||
else
|
||||
NUMBER = 1
|
||||
endif
|
||||
|
||||
ifdef JOB_BASE_NAME
|
||||
PROJECT_ENCODED_SLASH = $(subst %2F,$(TO),$(JOB_BASE_NAME))
|
||||
PROJECT = $(subst /,$(TO),$(PROJECT_ENCODED_SLASH))
|
||||
# Run on CI
|
||||
COMPOSE = docker-compose -f docker-compose.yml -f docker-compose.ci.yml -p $(PROJECTNAME)_$(PROJECT)_$(NUMBER)
|
||||
else
|
||||
# Run Locally
|
||||
COMPOSE = docker-compose -p $(PROJECTNAME)
|
||||
endif
|
||||
|
||||
.PHONY: init
|
||||
init:
|
||||
# This following command is used to provision the network
|
||||
$(COMPOSE) up --no-start --no-build app | true
|
||||
|
||||
.PHONY: build
|
||||
build:
|
||||
$(COMPOSE) run build
|
||||
|
||||
.PHONY: fmt
|
||||
format:
|
||||
$(COMPOSE) run fmt
|
||||
|
||||
.PHONY: lint
|
||||
lint:
|
||||
$(COMPOSE) run lint
|
||||
|
||||
.PHONY: test
|
||||
test:
|
||||
$(COMPOSE) run test
|
||||
|
||||
.PHONY: down
|
||||
down:
|
||||
$(COMPOSE) down --volumes
|
||||
Reference in New Issue
Block a user