Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat penumbra add support #423

Closed
wants to merge 12 commits into from
4 changes: 2 additions & 2 deletions .github/workflows/go.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: '>=1.20.2'
go-version: '>=1.21'
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
Expand All @@ -29,6 +29,6 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: '>=1.20.2'
go-version: '>=1.21'
- name: unit tests
run: make test
2 changes: 1 addition & 1 deletion .github/workflows/manifests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: '>=1.20.2'
go-version: '>=1.21'
- run: make generate manifests

- uses: CatChen/check-git-status-action@v1
Expand Down
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

# Image URL to use all building/pushing image targets
IMG ?= controller:latest
IMG ?= ghcr.io/strangelove-ventures/cosmos-operator:v0.21.7
# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
ENVTEST_K8S_VERSION = 1.24.1

Expand Down Expand Up @@ -139,7 +139,7 @@ $(LOCALBIN):
mkdir -p $(LOCALBIN)

## Tool Binaries
KUSTOMIZE ?= $(LOCALBIN)/kustomize
KUSTOMIZE ?= kustomize
CONTROLLER_GEN ?= $(LOCALBIN)/controller-gen
ENVTEST ?= $(LOCALBIN)/setup-envtest

Expand All @@ -149,9 +149,9 @@ CONTROLLER_TOOLS_VERSION ?= v0.14.0

KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh"
.PHONY: kustomize
kustomize: $(KUSTOMIZE) ## Download kustomize locally if necessary.
$(KUSTOMIZE): $(LOCALBIN)
curl -s $(KUSTOMIZE_INSTALL_SCRIPT) | bash -s -- $(subst v,,$(KUSTOMIZE_VERSION)) $(LOCALBIN)
#kustomize: $(KUSTOMIZE) ## Download kustomize locally if necessary.
#$(KUSTOMIZE): $(LOCALBIN)
# curl -s $(KUSTOMIZE_INSTALL_SCRIPT) | bash -s -- $(subst v,,$(KUSTOMIZE_VERSION)) $(LOCALBIN)

.PHONY: controller-gen
controller-gen: $(CONTROLLER_GEN) ## Download controller-gen locally if necessary.
Expand Down
23 changes: 23 additions & 0 deletions api/v1/cosmosfullnode_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,14 @@ type FullNodeSpec struct {
// +optional
Type FullNodeType `json:"type"`

// Different kinds of chains supported by the operator
// 'Cosmos' configures the node using defaults for a Cosmos based chain
// 'Custom' configures the node with more flexible options that allow for support other chains
// If not set, defaults to Cosmos
// +kubebuilder:validation:Enum:=Cosmos;Custom
// +optional
ChainType ChainType `json:"chainType"`

// Blockchain-specific configuration.
ChainSpec ChainSpec `json:"chain"`

Expand Down Expand Up @@ -102,6 +110,13 @@ const (
Sentry FullNodeType = "Sentry"
)

type ChainType string

const (
Cosmos ChainType = "Cosmos"
Custom ChainType = "Custom"
)

// FullNodeStatus defines the observed state of CosmosFullNode
type FullNodeStatus struct {
// INSERT ADDITIONAL STATUS FIELD - define observed state of cluster
Expand Down Expand Up @@ -450,6 +465,14 @@ type ChainSpec struct {
// +optional
LogFormat *string `json:"logFormat"`

// Specify shell (sh) script commands to initialize the chain
// +optional
InitScript *string `json:"initScript"`

// Specify shell (sh) script commands to start the chain
// +optional
StartScript *string `json:"startScript"`

// URL to address book file to download from the internet.
// The operator detects and properly handles the following file extensions:
// .json, .json.gz, .tar, .tar.gz, .tar.gzip, .zip
Expand Down
17 changes: 13 additions & 4 deletions api/v1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions api/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading