Skip to content

Commit

Permalink
Rename controllers to controller
Browse files Browse the repository at this point in the history
Signed-off-by: Hidde Beydals <hidde@hhh.computer>
  • Loading branch information
hiddeco committed May 25, 2023
1 parent 33592d2 commit 9720e24
Show file tree
Hide file tree
Showing 17 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ notes

# Thes are downloaded in the Makefile
cache/*
internal/controllers/testdata/crds/*
internal/controller/testdata/crds/*

# Binaries for programs and plugins
*.exe
Expand Down Expand Up @@ -33,4 +33,4 @@ testbin
build/

# CRDs for fuzzing tests.
internal/controllers/testdata/crd
internal/controller/testdata/crd
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ ifeq ($(shell uname -s),Darwin)
ENVTEST_ARCH=amd64
endif

TEST_CRDS := internal/controllers/testdata/crds
TEST_CRDS := internal/controller/testdata/crds

# Log level for `make run`
LOG_LEVEL ?= info
Expand Down
2 changes: 1 addition & 1 deletion docs/spec/v1beta1/imageupdateautomations.md
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ The message template is a [Go text template][go-text-template]. The data availab
have this structure (not reproduced verbatim):

```go
// controllers/imageupdateautomation_controller.go
// internal/controller/imageupdateautomation_controller.go
// TemplateData is the type of the value given to the commit message
// template.
Expand Down
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ import (
"github.com/fluxcd/pkg/git"

// +kubebuilder:scaffold:imports
"github.com/fluxcd/image-automation-controller/internal/controllers"
"github.com/fluxcd/image-automation-controller/internal/controller"
)

const (
Expand Down
12 changes: 6 additions & 6 deletions tests/fuzz/oss_fuzz_prebuild.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ set -euxo pipefail

# Some tests requires embedded resources. Embedding does not allow
# for traversing into ascending dirs, therefore we copy those contents here:
mkdir -p internal/controllers/testdata/crd
cp config/crd/bases/*.yaml internal/controllers/testdata/crd
mkdir -p internal/controller/testdata/crd
cp config/crd/bases/*.yaml internal/controller/testdata/crd

# Version of the source-controller from which to get the GitRepository CRD.
# Pulls source-controller/api's version set in go.mod.
Expand All @@ -32,10 +32,10 @@ SOURCE_VER=$(go list -m github.com/fluxcd/source-controller/api | awk '{print $2
# Pulls image-reflector-controller/api's version set in go.mod.
REFLECTOR_VER=$(go list -m github.com/fluxcd/image-reflector-controller/api | awk '{print $2}')

if [ -d "../../internal/controllers/testdata/crds" ]; then
cp ../../internal/controllers/testdata/crds/*.yaml testdata/crds
if [ -d "../../internal/controller/testdata/crds" ]; then
cp ../../internal/controller/testdata/crds/*.yaml testdata/crds
else
# Fetch the CRDs if not present since we need them when running fuzz tests on CI.
curl -s --fail https://raw.githubusercontent.com/fluxcd/source-controller/${SOURCE_VER}/config/crd/bases/source.toolkit.fluxcd.io_gitrepositories.yaml -o internal/controllers/testdata/crd/gitrepositories.yaml
curl -s --fail https://raw.githubusercontent.com/fluxcd/image-reflector-controller/${REFLECTOR_VER}/config/crd/bases/image.toolkit.fluxcd.io_imagepolicies.yaml -o internal/controllers/testdata/crd/imagepolicies.yaml
curl -s --fail https://raw.githubusercontent.com/fluxcd/source-controller/${SOURCE_VER}/config/crd/bases/source.toolkit.fluxcd.io_gitrepositories.yaml -o internal/controller/testdata/crd/gitrepositories.yaml
curl -s --fail https://raw.githubusercontent.com/fluxcd/image-reflector-controller/${REFLECTOR_VER}/config/crd/bases/image.toolkit.fluxcd.io_imagepolicies.yaml -o internal/controller/testdata/crd/imagepolicies.yaml
fi

0 comments on commit 9720e24

Please sign in to comment.