Fixed sed command on macOS
This commit is contained in:
parent
546edb4d9f
commit
b1696e5d9e
23
Makefile
23
Makefile
|
|
@ -2,6 +2,19 @@
|
||||||
SHELL := /bin/sh
|
SHELL := /bin/sh
|
||||||
PATH := $(GOPATH)/bin:$(PATH)
|
PATH := $(GOPATH)/bin:$(PATH)
|
||||||
|
|
||||||
|
OSFLAG :=
|
||||||
|
ifeq ($(OS),Windows_NT)
|
||||||
|
OSFLAG = WIN32
|
||||||
|
else
|
||||||
|
UNAME_S := $(shell uname -s)
|
||||||
|
ifeq ($(UNAME_S),Linux)
|
||||||
|
OSFLAG = LINUX
|
||||||
|
endif
|
||||||
|
ifeq ($(UNAME_S),Darwin)
|
||||||
|
OSFLAG = OSX
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
# Import config
|
# Import config
|
||||||
# You can change the default config with `make config="config_special.env" build`
|
# You can change the default config with `make config="config_special.env" build`
|
||||||
config ?= config.env
|
config ?= config.env
|
||||||
|
|
@ -157,10 +170,20 @@ e2e: build docker-build ## Runs e2e tests, you can use EXTRA_ARGS
|
||||||
cat deploy/role.yaml >> deploy/namespace-init.yaml
|
cat deploy/role.yaml >> deploy/namespace-init.yaml
|
||||||
cat deploy/role_binding.yaml >> deploy/namespace-init.yaml
|
cat deploy/role_binding.yaml >> deploy/namespace-init.yaml
|
||||||
cat deploy/operator.yaml >> deploy/namespace-init.yaml
|
cat deploy/operator.yaml >> deploy/namespace-init.yaml
|
||||||
|
ifeq ($(OSFLAG), LINUX)
|
||||||
sed -i 's|\(image:\).*|\1 $(DOCKER_REGISTRY):$(GITCOMMIT)|g' deploy/namespace-init.yaml
|
sed -i 's|\(image:\).*|\1 $(DOCKER_REGISTRY):$(GITCOMMIT)|g' deploy/namespace-init.yaml
|
||||||
ifeq ($(KUBECTL_CONTEXT),minikube)
|
ifeq ($(KUBECTL_CONTEXT),minikube)
|
||||||
sed -i 's|\(imagePullPolicy\): IfNotPresent|\1: Never|g' deploy/namespace-init.yaml
|
sed -i 's|\(imagePullPolicy\): IfNotPresent|\1: Never|g' deploy/namespace-init.yaml
|
||||||
sed -i 's|\(args:\).*|\1\ ["--minikube"\]|' deploy/namespace-init.yaml
|
sed -i 's|\(args:\).*|\1\ ["--minikube"\]|' deploy/namespace-init.yaml
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
ifeq ($(OSFLAG), OSX)
|
||||||
|
sed -i '' 's|\(image:\).*|\1 $(DOCKER_REGISTRY):$(GITCOMMIT)|g' deploy/namespace-init.yaml
|
||||||
|
ifeq ($(KUBECTL_CONTEXT),minikube)
|
||||||
|
sed -i '' 's|\(imagePullPolicy\): IfNotPresent|\1: Never|g' deploy/namespace-init.yaml
|
||||||
|
sed -i '' 's|\(args:\).*|\1\ ["--minikube"\]|' deploy/namespace-init.yaml
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@RUNNING_TESTS=1 go test -parallel=1 "./test/e2e/" -tags "$(BUILDTAGS) cgo" -v -timeout 30m -run "$(E2E_TEST_SELECTOR)" \
|
@RUNNING_TESTS=1 go test -parallel=1 "./test/e2e/" -tags "$(BUILDTAGS) cgo" -v -timeout 30m -run "$(E2E_TEST_SELECTOR)" \
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,22 @@ import (
|
||||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
|
func (in *AppliedGroovyScript) DeepCopyInto(out *AppliedGroovyScript) {
|
||||||
|
*out = *in
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AppliedGroovyScript.
|
||||||
|
func (in *AppliedGroovyScript) DeepCopy() *AppliedGroovyScript {
|
||||||
|
if in == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
out := new(AppliedGroovyScript)
|
||||||
|
in.DeepCopyInto(out)
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
func (in *Backup) DeepCopyInto(out *Backup) {
|
func (in *Backup) DeepCopyInto(out *Backup) {
|
||||||
*out = *in
|
*out = *in
|
||||||
|
|
@ -50,6 +66,39 @@ func (in *Build) DeepCopy() *Build {
|
||||||
return out
|
return out
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
|
func (in *ConfigMapRef) DeepCopyInto(out *ConfigMapRef) {
|
||||||
|
*out = *in
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigMapRef.
|
||||||
|
func (in *ConfigMapRef) DeepCopy() *ConfigMapRef {
|
||||||
|
if in == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
out := new(ConfigMapRef)
|
||||||
|
in.DeepCopyInto(out)
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
|
func (in *ConfigurationAsCode) DeepCopyInto(out *ConfigurationAsCode) {
|
||||||
|
*out = *in
|
||||||
|
in.Customization.DeepCopyInto(&out.Customization)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConfigurationAsCode.
|
||||||
|
func (in *ConfigurationAsCode) DeepCopy() *ConfigurationAsCode {
|
||||||
|
if in == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
out := new(ConfigurationAsCode)
|
||||||
|
in.DeepCopyInto(out)
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
func (in *Container) DeepCopyInto(out *Container) {
|
func (in *Container) DeepCopyInto(out *Container) {
|
||||||
*out = *in
|
*out = *in
|
||||||
|
|
@ -123,6 +172,45 @@ func (in *Container) DeepCopy() *Container {
|
||||||
return out
|
return out
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
|
func (in *Customization) DeepCopyInto(out *Customization) {
|
||||||
|
*out = *in
|
||||||
|
out.Secret = in.Secret
|
||||||
|
if in.Configurations != nil {
|
||||||
|
in, out := &in.Configurations, &out.Configurations
|
||||||
|
*out = make([]ConfigMapRef, len(*in))
|
||||||
|
copy(*out, *in)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Customization.
|
||||||
|
func (in *Customization) DeepCopy() *Customization {
|
||||||
|
if in == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
out := new(Customization)
|
||||||
|
in.DeepCopyInto(out)
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
|
func (in *GroovyScripts) DeepCopyInto(out *GroovyScripts) {
|
||||||
|
*out = *in
|
||||||
|
in.Customization.DeepCopyInto(&out.Customization)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GroovyScripts.
|
||||||
|
func (in *GroovyScripts) DeepCopy() *GroovyScripts {
|
||||||
|
if in == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
out := new(GroovyScripts)
|
||||||
|
in.DeepCopyInto(out)
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
func (in *Handler) DeepCopyInto(out *Handler) {
|
func (in *Handler) DeepCopyInto(out *Handler) {
|
||||||
*out = *in
|
*out = *in
|
||||||
|
|
@ -277,6 +365,8 @@ func (in *JenkinsSpec) DeepCopyInto(out *JenkinsSpec) {
|
||||||
in.SlaveService.DeepCopyInto(&out.SlaveService)
|
in.SlaveService.DeepCopyInto(&out.SlaveService)
|
||||||
in.Backup.DeepCopyInto(&out.Backup)
|
in.Backup.DeepCopyInto(&out.Backup)
|
||||||
in.Restore.DeepCopyInto(&out.Restore)
|
in.Restore.DeepCopyInto(&out.Restore)
|
||||||
|
in.GroovyScripts.DeepCopyInto(&out.GroovyScripts)
|
||||||
|
in.ConfigurationAsCode.DeepCopyInto(&out.ConfigurationAsCode)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -317,6 +407,11 @@ func (in *JenkinsStatus) DeepCopyInto(out *JenkinsStatus) {
|
||||||
*out = make([]string, len(*in))
|
*out = make([]string, len(*in))
|
||||||
copy(*out, *in)
|
copy(*out, *in)
|
||||||
}
|
}
|
||||||
|
if in.AppliedGroovyScripts != nil {
|
||||||
|
in, out := &in.AppliedGroovyScripts, &out.AppliedGroovyScripts
|
||||||
|
*out = make([]AppliedGroovyScript, len(*in))
|
||||||
|
copy(*out, *in)
|
||||||
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -363,6 +458,22 @@ func (in *Restore) DeepCopy() *Restore {
|
||||||
return out
|
return out
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
|
func (in *SecretRef) DeepCopyInto(out *SecretRef) {
|
||||||
|
*out = *in
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SecretRef.
|
||||||
|
func (in *SecretRef) DeepCopy() *SecretRef {
|
||||||
|
if in == nil {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
out := new(SecretRef)
|
||||||
|
in.DeepCopyInto(out)
|
||||||
|
return out
|
||||||
|
}
|
||||||
|
|
||||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||||
func (in *SeedJob) DeepCopyInto(out *SeedJob) {
|
func (in *SeedJob) DeepCopyInto(out *SeedJob) {
|
||||||
*out = *in
|
*out = *in
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue