Skip to content

Commit

Permalink
use github.com/ushitora-anqou/magout as repo
Browse files Browse the repository at this point in the history
  • Loading branch information
ushitora-anqou committed Sep 3, 2024
1 parent fb9658b commit 6a4fe5d
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 15 deletions.
4 changes: 2 additions & 2 deletions PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ domain: magout.anqou.net
layout:
- go.kubebuilder.io/v4
projectName: magout
repo: magout.anqou.net/magout
repo: github.com/ushitora-anqou/magout
resources:
- api:
crdVersion: v1
namespaced: true
controller: true
domain: magout.anqou.net
kind: MastodonServer
path: magout.anqou.net/magout/api/v1
path: github.com/ushitora-anqou/magout/api/v1
version: v1
version: "3"
6 changes: 3 additions & 3 deletions cmd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import (
metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server"
"sigs.k8s.io/controller-runtime/pkg/webhook"

magoutanqounetv1 "magout.anqou.net/magout/api/v1"
"magout.anqou.net/magout/internal/controller"
magoutv1 "github.com/ushitora-anqou/magout/api/v1"
"github.com/ushitora-anqou/magout/internal/controller"
// +kubebuilder:scaffold:imports
)

Expand All @@ -32,7 +32,7 @@ var (
func init() {
utilruntime.Must(clientgoscheme.AddToScheme(scheme))

utilruntime.Must(magoutanqounetv1.AddToScheme(scheme))
utilruntime.Must(magoutv1.AddToScheme(scheme))
// +kubebuilder:scaffold:scheme
}

Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
module magout.anqou.net/magout
module github.com/ushitora-anqou/magout

go 1.22.0

require (
github.com/onsi/ginkgo/v2 v2.19.0
github.com/onsi/gomega v1.33.1
k8s.io/api v0.31.0
k8s.io/apimachinery v0.31.0
k8s.io/client-go v0.31.0
sigs.k8s.io/controller-runtime v0.19.0
Expand Down Expand Up @@ -84,7 +85,6 @@ require (
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/api v0.31.0 // indirect
k8s.io/apiextensions-apiserver v0.31.0 // indirect
k8s.io/apiserver v0.31.0 // indirect
k8s.io/component-base v0.31.0 // indirect
Expand Down
4 changes: 2 additions & 2 deletions internal/controller/mastodonserver_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"sigs.k8s.io/controller-runtime/pkg/client"
"sigs.k8s.io/controller-runtime/pkg/log"

magoutanqounetv1 "magout.anqou.net/magout/api/v1"
magoutv1 "github.com/ushitora-anqou/magout/api/v1"
)

// MastodonServerReconciler reconciles a MastodonServer object
Expand Down Expand Up @@ -41,6 +41,6 @@ func (r *MastodonServerReconciler) Reconcile(ctx context.Context, req ctrl.Reque
// SetupWithManager sets up the controller with the Manager.
func (r *MastodonServerReconciler) SetupWithManager(mgr ctrl.Manager) error {
return ctrl.NewControllerManagedBy(mgr).
For(&magoutanqounetv1.MastodonServer{}).
For(&magoutv1.MastodonServer{}).
Complete(r)
}
8 changes: 4 additions & 4 deletions internal/controller/mastodonserver_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import (

metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"

magoutanqounetv1 "magout.anqou.net/magout/api/v1"
magoutv1 "github.com/ushitora-anqou/magout/api/v1"
)

var _ = Describe("MastodonServer Controller", func() {
Expand All @@ -24,13 +24,13 @@ var _ = Describe("MastodonServer Controller", func() {
Name: resourceName,
Namespace: "default", // TODO(user):Modify as needed
}
mastodonserver := &magoutanqounetv1.MastodonServer{}
mastodonserver := &magoutv1.MastodonServer{}

BeforeEach(func() {
By("creating the custom resource for the Kind MastodonServer")
err := k8sClient.Get(ctx, typeNamespacedName, mastodonserver)
if err != nil && errors.IsNotFound(err) {
resource := &magoutanqounetv1.MastodonServer{
resource := &magoutv1.MastodonServer{
ObjectMeta: metav1.ObjectMeta{
Name: resourceName,
Namespace: "default",
Expand All @@ -43,7 +43,7 @@ var _ = Describe("MastodonServer Controller", func() {

AfterEach(func() {
// TODO(user): Cleanup logic after each test, like removing the resource instance.
resource := &magoutanqounetv1.MastodonServer{}
resource := &magoutv1.MastodonServer{}
err := k8sClient.Get(ctx, typeNamespacedName, resource)
Expect(err).NotTo(HaveOccurred())

Expand Down
4 changes: 2 additions & 2 deletions internal/controller/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (
logf "sigs.k8s.io/controller-runtime/pkg/log"
"sigs.k8s.io/controller-runtime/pkg/log/zap"

magoutanqounetv1 "magout.anqou.net/magout/api/v1"
magoutv1 "github.com/ushitora-anqou/magout/api/v1"
// +kubebuilder:scaffold:imports
)

Expand Down Expand Up @@ -61,7 +61,7 @@ var _ = BeforeSuite(func() {
Expect(err).NotTo(HaveOccurred())
Expect(cfg).NotTo(BeNil())

err = magoutanqounetv1.AddToScheme(scheme.Scheme)
err = magoutv1.AddToScheme(scheme.Scheme)
Expect(err).NotTo(HaveOccurred())

// +kubebuilder:scaffold:scheme
Expand Down

0 comments on commit 6a4fe5d

Please sign in to comment.