diff --git a/.gitignore b/.gitignore index dea52e7..c4d0997 100644 --- a/.gitignore +++ b/.gitignore @@ -21,4 +21,4 @@ workspace/ kusion_state.yaml # local bin files -models/bin/ \ No newline at end of file +modules/bin/ \ No newline at end of file diff --git a/kcl.mod b/kcl.mod deleted file mode 100644 index 7ff17c6..0000000 --- a/kcl.mod +++ /dev/null @@ -1,4 +0,0 @@ -[package] -name = "catalog" -edition = "0.5.0" -version = "0.1.0" diff --git a/models/schema/v1/app_configuration.k b/models/schema/v1/app_configuration.k deleted file mode 100644 index 388aa28..0000000 --- a/models/schema/v1/app_configuration.k +++ /dev/null @@ -1,59 +0,0 @@ -import models.schema.v1.workload as wl -import models.schema.v1.trait as t -import models.schema.v1.monitoring as m -import models.schema.v1.accessories.mysql -import models.schema.v1.accessories.postgres - -schema AppConfiguration: - """ AppConfiguration is a developer-centric definition that describes how to run an Application. - This application model builds upon a decade of experience at AntGroup running super large scale - internal developer platform, combined with best-of-breed ideas and practices from the community. - - Attributes - ---------- - workload: wl.Service | wl.Job, default is Undefined, required. - Workload defines how to run your application code. Currently supported workload profile - includes Service and Job. - monitoring: m.Prometheus, default is Undefined, optional. - Monitoring specifies how to scrape Prometheus metrics for the workload. - database: {str:mysql.MySQL | postgres.PostgreSQL}, defualt is Undefined, optional. - Database describes a locally deployed or a cloud provider managed database instance - for the workload. Currently supported database profile includes MySQL and PostgreSQL. - opsRule: t.OpsRule, default is Undefined, optional. - OpsRule specifies collection of rules that will be checked for Day-2 operation. - database: db.Database, default is Undefined, optional. - Database describes a locally deployed or a cloud provider managed database instance for the workload. - labels: {str:str}, default is Undefined, optional. - Labels can be used to attach arbitrary metadata as key-value pairs to resources. - annotations: {str:str}, default is Undefined, optional. - Annotations are key/value pairs that attach arbitrary non-identifying metadata to resources. - - Examples - -------- - # Instantiate an App with a long-running service and its image is "nginx:v1" - - import catalog.models.schema.v1 as ac - import catalog.models.schema.v1.workload as wl - import catalog.models.schema.v1.workload.container as c - - helloworld : ac.AppConfiguration { - workload: wl.Service { - containers: { - "nginx": c.Container { - image: "nginx:v1" - } - } - } - } - """ - - # Workload defines how to run your application code. - workload: wl.Service | wl.Job - - # Accessories defines a collection of accessories that will be attached to the workload. The key in this map represents the module source. e.g. kusionstack/mysql@v0.1 - accessories: {str:any} - - ###### Other metadata info - # Labels and annotations can be used to attach arbitrary metadata as key-value pairs to resources. - labels?: {str:str} - annotations?: {str:str} \ No newline at end of file diff --git a/models/schema/v1/workload/common.k b/models/schema/v1/workload/common.k deleted file mode 100644 index 0bfe321..0000000 --- a/models/schema/v1/workload/common.k +++ /dev/null @@ -1,35 +0,0 @@ -import models.schema.v1.workload.container as c -import models.schema.v1.workload.secret as sec - -schema WorkloadBase: - """ WorkloadBase defines set of attributes shared by different workload profile, e.g Service - and Job. You can inherit this Schema to reuse these common attributes. - - Attributes - ---------- - containers: {str:c.Container}, default is Undefined, required. - Containers defines the templates of containers to be ran. - More info: https://kubernetes.io/docs/concepts/containers - secrets: {str:sec.Secret}, default is Undefined, optional. - Secrets can be used to store small amount of sensitive data e.g. password, token. - replicas: int, optional. - Number of container replicas based on this configuration that should be ran. - labels: {str:str}, default is Undefined, optional. - Labels are key/value pairs that are attached to the workload. - annotations: {str:str}, default is Undefined, optional. - Annotations are key/value pairs that attach arbitrary non-identifying metadata to the workload. - """ - - # The templates of containers to be ran. - containers: {str:c.Container} - - # Secrets store small amount of sensitive data e.g. a password, a token, or a key. - secrets?: {str:sec.Secret} - - # The number of containers that should be ran. - replicas?: int - - ###### Other metadata info - # Labels and annotations can be used to attach arbitrary metadata as key-value pairs to resources. - labels?: {str:str} - annotations?: {str:str} diff --git a/models/schema/v1/workload/container/container.k b/models/schema/v1/workload/container/container.k deleted file mode 100644 index 6f24448..0000000 --- a/models/schema/v1/workload/container/container.k +++ /dev/null @@ -1,146 +0,0 @@ -import models.schema.v1.workload.container.probe as p -import models.schema.v1.workload.container.lifecycle as lc - -import regex - -schema Container: - """ Container describes how the Application's tasks are expected to be run. Depending on - the replicas parameter 1 or more containers can be created from each template. - - Attributes - ---------- - image: str, default is Undefined, required. - Image refers to the Docker image name to run for this container. - More info: https://kubernetes.io/docs/concepts/containers/images - command: [str], default is Undefined, optional. - Entrypoint array. Not executed within a shell. - Command will overwrite the ENTRYPOINT value set in the Dockfile, otherwise the Docker - image's ENTRYPOINT is used if this is not provided. - args: [str], default is Undefined, optional. - Arguments to the entrypoint. - Args will overwrite the CMD value set in the Dockfile, otherwise the Docker - image's CMD is used if this is not provided. - env: {str:str}, default is Undefined, optional. - List of environment variables to set in the container. - The value of the environment variable may be static text or a value from a secret. - workingDir: str, default is Undefined, optional. - The working directory of the running process defined in entrypoint. - Default container runtime will be used if this is not specified. - resources: {str:str}, default is Undefined, optional. - Map of resource requirements the container should run with. - The resources parameter is a dict with the key being the resource name and the value being - the resource value. - files: {str:FileSpec}, default is Undefined, optional. - List of files to create in the container. - The files parameter is a dict with the key being the file name in the container and the value - being the target file specification. - dirs: {str:str}, default is Undefined, optional. - Collection of volumes mount into the container's filesystem. - The dirs parameter is a dict with the key being the folder name in the container and the value - being the referenced volume. - livenessProbe: p.Probe, default is Undefined, optional. - LivenessProbe indicates if a running process is healthy. - Container will be restarted if the probe fails. - readinessProbe: p.Probe, default is Undefined, optional. - ReadinessProbe indicates whether an application is available to handle requests. - startupProbe: p.Probe, default is Undefined, optional. - StartupProbe indicates that the container has started for the first time. - Container will be restarted if the probe fails. - lifecycle: lc.Lifecycle, default is Undefined, optional. - Lifecycle refers to actions that the management system should take in response to container lifecycle events. - - Examples - -------- - import catalog.models.schema.v1.workload.container as c - - web = c.Container { - image: "nginx:latest" - command: ["/bin/sh", "-c", "echo hi"] - env: { - "name": "value" - } - resources: { - "cpu": "2" - "memory": "4Gi" - } - } - """ - - # Image to run for this container. - image: str - - # Entrypoint array. - # The image's ENTRYPOINT is used if this is not provided. - command?: [str] - # Arguments to the entrypoint. - # The image's CMD is used if this is not provided. - args?: [str] - # Collection of environment variables to set in the container. - # The value of environment variable may be static text or a value from a secret. - env?: {str:str} - # The current working directory of the running process defined in entrypoint. - workingDir?: str - - # Resource requirements for this container. - resources?: {str:str} - - # Files configures one or more files to be created in the container. - files?: {str:FileSpec} - # Dirs configures one or more volumes to be mounted to the specified folder. - dirs?: {str:str} - - # Liveness probe for this container. - # Liveness probe indicates if a running process is healthy. - livenessProbe?: p.Probe - # Readiness probe for this container. - # Readiness probe indicates whether an application is available to handle requests. - readinessProbe?: p.Probe - # Startup probe for this container. - # Startup probe indicates that the container has started for the first time. - startupProbe?: p.Probe - - # Lifecycle configures actions which should be taken response to container lifecycle - # events. - lifecycle?: lc.Lifecycle - - check: - all e in env { - regex.match(e, r"^[-._a-zA-Z][-._a-zA-Z0-9]*$") - } if env, "a valid environment variable name must consist of alphabetic characters, digits, '_', '-', or '.', and must not start with a digit" - -schema FileSpec: - """ FileSpec defines the target file in a Container. - - Attributes - ---------- - content: str, default is Undefined, optional. - File content in plain text. - contentFrom: str, default is Undefined, optional. - Source for the file content, reference to a secret of configmap value. - mode: str, default is Undefined, optional. - Mode bits used to set permissions on this file, must be an octal value - between 0000 and 0777 or a decimal value between 0 and 511 - - Examples - -------- - import catalog.models.schema.v1.workload.container as c - - tmpFile = c.FileSpec { - content: "some file contents" - mode: "0777" - } - """ - - # The content of target file in plain text. - content?: str - - # Source for the file content, might be a reference to a secret value. - contentFrom?: str - - # Mode bits used to set permissions on this file. - # Defaults to 0644. - mode: str = "0644" - - check: - not content or not contentFrom, "content and contentFrom are mutually exclusive" - regex.match(mode, r"^[0-7]{3,4}$"), "valid mode must between 0000 and 0777, both inclusive" diff --git a/models/schema/v1/workload/container/lifecycle/lifecycle.k b/models/schema/v1/workload/container/lifecycle/lifecycle.k deleted file mode 100644 index 725a1b5..0000000 --- a/models/schema/v1/workload/container/lifecycle/lifecycle.k +++ /dev/null @@ -1,36 +0,0 @@ -import models.schema.v1.workload.container.probe as p - -schema Lifecycle: - """ Lifecycle describes actions that the management system should take in response - to container lifecycle events. - - Attributes - ---------- - preStop: p.Exec | p.Http, default is Undefined, optional. - The action to be taken before a container is terminated due to an API request or - management event such as liveness/startup probe failure, preemption, resource contention, etc. - More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks - postStart: p.Exec | p.Http, default is Undefined, optional. - The action to be taken after a container is created. - More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks - - Examples - -------- - import catalog.models.schema.v1.workload.container.probe as p - import catalog.models.schema.v1.workload.container.lifecycle as lc - - lifecycleHook = lc.Lifecycle { - preStop: p.Exec { - command: ["preStop.sh"] - } - postStart: p.Http { - url: "http://localhost:80" - } - } - """ - - # The action to be taken before a container is terminated. - preStop?: p.Exec | p.Http - - # The action to be taken after a container is created. - postStart?: p.Exec | p.Http diff --git a/models/schema/v1/workload/container/probe/probe.k b/models/schema/v1/workload/container/probe/probe.k deleted file mode 100644 index 2af8a1b..0000000 --- a/models/schema/v1/workload/container/probe/probe.k +++ /dev/null @@ -1,142 +0,0 @@ -import regex - -schema Probe: - """ Probe describes a health check to be performed against a container to determine whether it is - alive or ready to receive traffic. There are three probe types: readiness, liveness, and startup. - - Attributes - ---------- - probeHandler: Exec | Http | Tcp, default is Undefined, required. - The action taken to determine the alive or health of a container - initialDelaySeconds: int, default is Undefined, optional. - The number of seconds before health checking is activated. - More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes - timeoutSeconds: int, default is Undefined, optional. - The number of seconds after which the probe times out. - More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes - periodSeconds: int, default is Undefined, optional. - How often (in seconds) to perform the probe. - successThreshold: int, default is Undefined, optional. - Minimum consecutive successes for the probe to be considered successful after having failed. - failureThreshold: int, default is Undefined, optional. - Minimum consecutive failures for the probe to be considered failed after having succeeded. - terminationGracePeriod: int, default is Undefined, optional. - Duration in seconds before terminate gracefully upon probe failure. - - Examples - -------- - import catalog.models.schema.v1.workload.container.probe as p - - probe = p.Probe { - probeHandler: p.Http { - path: "/healthz" - } - initialDelaySeconds: 10 - } - """ - - # The action taken to determine the health of a container - probeHandler: Exec | Http | Tcp - - # Number of seconds after the container has started before liveness probes are initiated. - initialDelaySeconds?: int - - # Number of seconds after which the probe times out. - timeoutSeconds?: int - - # How often (in seconds) to perform the probe. - periodSeconds?: int - - # Minimum consecutive successes for the probe to be considered successful after having failed. - successThreshold?: int - - # Minimum consecutive failures for the probe to be considered failed after having succeeded. - failureThreshold?: int - - # Duration in seconds before terminate gracefully upon probe failure. - terminationGracePeriod?: int - - check: - initialDelaySeconds >= 0 if initialDelaySeconds, "initialDelaySeconds must be greater than or equal to 0" - timeoutSeconds >= 0 if timeoutSeconds, "timeoutSeconds must be greater than or equal to 0" - periodSeconds >= 0 if periodSeconds, "periodSeconds must be greater than or equal to 0" - successThreshold >= 0 if successThreshold, "successThreshold must be greater than or equal to 0" - failureThreshold >= 0 if failureThreshold, "failureThreshold must be greater than or equal to 0" - terminationGracePeriod >= 0 if terminationGracePeriod, "terminationGracePeriod must be greater than or equal to 0" - -schema Exec: - """ Exec describes a "run in container" action. - - Attributes - ---------- - command: [str], default is Undefined, required. - The command line to execute inside the container. - - Examples - -------- - import catalog.models.schema.v1.workload.container.probe as p - - execProbe = p.Exec { - command: ["probe.sh"] - } - """ - - # The command line to execute inside the container. - # Exit status of 0 is treated as live/healthy and non-zero is unhealthy. - command: [str] - - check: - len(command) > 0, "command must be specified" - -schema Http: - """ Http describes an action based on HTTP Get requests. - - Attributes - ---------- - url: str, default is Undefined, required. - The full qualified url to send HTTP requests. - headers: {str:str}, default is Undefined, optional. - Collection of custom headers to set in the request - - Examples - -------- - import catalog.models.schema.v1.workload.container.probe as p - - httpProbe = p.Http { - url: "http://localhost:80" - headers: { - "X-HEADER": "VALUE" - } - } - """ - - # The full qualified url to send HTTP requests. - url: str - - # Custom headers to set in the request. - headers?: {str:str} - - check: - all header in headers { - regex.match(header, r"^[-A-Za-z0-9]+$") - } if headers, "a valid HTTP header must consist of alphanumeric characters or '-' e.g X-Header-Name" - -schema Tcp: - """ Tcp describes an action based on opening a socket. - - Attributes - ---------- - url: str, default is Undefined, required. - The full qualified url to open a socket. - - Examples - -------- - import catalog.models.schema.v1.workload.container.probe as p - - tcpProbe = p.Tcp { - url: "tcp://localhost:1234" - } - """ - - # The full qualified url to open a socket. - url: str diff --git a/models/schema/v1/workload/job.k b/models/schema/v1/workload/job.k deleted file mode 100644 index da8551a..0000000 --- a/models/schema/v1/workload/job.k +++ /dev/null @@ -1,30 +0,0 @@ -schema Job(WorkloadBase): - """ Job is a kind of workload profile that describes how to run your application code. This - is typically used for tasks that take from a few seconds to a few days to complete. - - Attributes - ---------- - schedule: str, default is Undefined, required. - The scheduling strategy in Cron format. More info: https://en.wikipedia.org/wiki/Cron. - - Examples - -------- - Instantiate a job with busybox image and runs every hour - - import catalog.models.schema.v1.workload as wl - import catalog.models.schema.v1.workload.container as c - - echoJob : wl.Job { - containers: { - "busybox": c.Container{ - image: "busybox:1.28" - command: ["/bin/sh", "-c", "echo hello"] - } - } - schedule: "0 * * * *" - } - """ - - # The scheduling strategy in Cron format. - # More info: https://en.wikipedia.org/wiki/Cron. - schedule: str diff --git a/models/schema/v1/workload/network/port.k b/models/schema/v1/workload/network/port.k deleted file mode 100644 index 522febb..0000000 --- a/models/schema/v1/workload/network/port.k +++ /dev/null @@ -1,42 +0,0 @@ -schema Port: - """ Port defines the exposed port of Service, which can be used to describe how the Service - get accessed. - - Attributes - ---------- - port: int, default is 80, required. - The exposed port of the Service. - targetPort: int, default is Undefined, optional. - The backend container port. If empty, set it the same as the port. - protocol: "TCP" | "UDP", default is "TCP", required. - The protocol to access the port. - public: bool, default is False, required. - Public defines whether the port can be accessed through Internet. - - Examples - -------- - import catalog.models.schema.v1.workload.network as n - - port = n.Port { - port: 80 - targetPort: 8080 - protocol: "TCP" - public: True - } - """ - - # The exposed port of the Service. - port: int = 80 - - # The backend container port. - targetPort?: int - - # The protocol of port. - protocol: "TCP" | "UDP" = "TCP" - - # Public defines whether to expose the port through Internet. - public: bool = False - - check: - 1 <= port <= 65535, "port must be between 1 and 65535, inclusive" - 1 <= targetPort <= 65535 if targetPort, "targetPort must be between 1 and 65535, inclusive" \ No newline at end of file diff --git a/models/schema/v1/workload/secret/secret.k b/models/schema/v1/workload/secret/secret.k deleted file mode 100644 index 2626bd2..0000000 --- a/models/schema/v1/workload/secret/secret.k +++ /dev/null @@ -1,59 +0,0 @@ -import regex - -# mapping between secret type and valid data key -SECRET_TYPE_DATA_MAPPING: {str:[str]} = { - "basic": ["username", "password"] - "token": ["token"] - "certificate": ["tls.crt", "tls.key"] - # empty array means no pre-defined data keys - "opaque": [] - "external": [] -} - -schema Secret: - """ Secrets are used to provide data that is considered sensitive like passwords, API keys, - TLS certificates, tokens or other credentials. - - Attributes - ---------- - type: str, default is Undefined, required. - Type of secret, used to facilitate programmatic handling of secret data. - params: {str:str}, default is Undefined, optional. - Collection of parameters used to facilitate programmatic handling of secret data. - data: {str:str}, default is Undefined, optional. - Data contains the non-binary secret data in string form. - immutable: bool, default is Undefined, optional. - Immutable, if set to true, ensures that data stored in the Secret cannot be updated. - - Examples - -------- - import catalog.models.schema.v1.workload.secret as sec - - basicAuth = sec.Secret { - type: "basic" - data: { - "username": "" - "password": "" - } - } - """ - - # Types of secrets available to use. - type: "basic" | "token" | "opaque" | "certificate" | "external" - - # Params defines extra parameters used to customize secret handling. - params?: {str:str} - - # Data defines the keys and data that will be used by secret. - data?: {str:str} - - # If immutable set to true, ensures that data stored in the Secret cannot be updated. - immutable?: bool - - check: - all k in data { - regex.match(k, r"[A-Za-z0-9_.-]*") - } if data, "a valid secret data key must consist of alphanumeric characters, '-', '_' or '.'" - all k in data { - k in SECRET_TYPE_DATA_MAPPING[type] if len(SECRET_TYPE_DATA_MAPPING[type]) > 0 - } if data, "a valid secret data key name must be one of ${SECRET_TYPE_DATA_MAPPING[type]} for ${type} type secret" \ No newline at end of file diff --git a/models/schema/v1/workload/service.k b/models/schema/v1/workload/service.k deleted file mode 100644 index 3384505..0000000 --- a/models/schema/v1/workload/service.k +++ /dev/null @@ -1,40 +0,0 @@ -import models.schema.v1.workload.network as n - -schema Service(WorkloadBase): - """ Service is a kind of workload profile that describes how to run your application code. This - is typically used for long-running web applications that should "never" go down, and handle - short-lived latency-sensitive web requests, or events. - - Attributes - ---------- - ports: [n.Port], default is Undefined, optional. - The list of ports which the Service should get exposed. - - Examples - -------- - # Instantiate a long-running service and its image is "nginx:v1" - - import catalog.models.schema.v1.workload as wl - import catalog.models.schema.v1.workload.container as c - import catalog.models.schema.v1.workload.network as n - - nginxSvc : wl.Service { - containers: { - "nginx": c.Container { - image: "nginx:v1" - } - } - ports: [ - n.Port { - port: 80 - public: True - } - n.Port { - port: 9090 - } - ] - } - """ - - # The list of ports get exposed. - ports?: [n.Port] diff --git a/models/schema/v1/monitoring/prometheus.k b/modules/monitoring/prometheus.k similarity index 100% rename from models/schema/v1/monitoring/prometheus.k rename to modules/monitoring/prometheus.k diff --git a/models/schema/v1/accessories/mysql.k b/modules/mysql/mysql.k similarity index 100% rename from models/schema/v1/accessories/mysql.k rename to modules/mysql/mysql.k diff --git a/modules/opsrule/example/dev/example.k b/modules/opsrule/example/dev/example.k new file mode 100644 index 0000000..0f33d66 --- /dev/null +++ b/modules/opsrule/example/dev/example.k @@ -0,0 +1,19 @@ +import opsrule as o +import kam.v1.app_configuration as ac +import kam.v1.workload as wl +import kam.v1.workload.container as c + +helloworld : ac.AppConfiguration { + workload: wl.Service { + containers: { + "nginx": c.Container { + image: "nginx:v1" + } + } + } + accessories: { + "opsRule": o.OpsRule { + maxUnavailable: "30%" + } + } +} \ No newline at end of file diff --git a/modules/opsrule/example/dev/kcl.mod b/modules/opsrule/example/dev/kcl.mod new file mode 100644 index 0000000..69ddd18 --- /dev/null +++ b/modules/opsrule/example/dev/kcl.mod @@ -0,0 +1,7 @@ +[package] +name = "example" +version = "0.1.0" + +[dependencies] +opsrule = { oci = "oci://ghcr.io/kusionstack/opsrule", tag = "0.0.1" } +kam = { git = "https://github.com/KusionStack/kam.git", tag = "0.1.0" } diff --git a/modules/opsrule/example/dev/stack.yaml b/modules/opsrule/example/dev/stack.yaml new file mode 100644 index 0000000..f0811d9 --- /dev/null +++ b/modules/opsrule/example/dev/stack.yaml @@ -0,0 +1 @@ +name: dev \ No newline at end of file diff --git a/modules/opsrule/example/project.yaml b/modules/opsrule/example/project.yaml new file mode 100644 index 0000000..66147a5 --- /dev/null +++ b/modules/opsrule/example/project.yaml @@ -0,0 +1 @@ +name: example \ No newline at end of file diff --git a/modules/opsrule/kcl.mod b/modules/opsrule/kcl.mod new file mode 100644 index 0000000..8d008ab --- /dev/null +++ b/modules/opsrule/kcl.mod @@ -0,0 +1,3 @@ +[package] +name = "opsrule" +version = "0.1.0" \ No newline at end of file diff --git a/models/schema/v1/trait/opsrule.k b/modules/opsrule/opsrule.k similarity index 62% rename from models/schema/v1/trait/opsrule.k rename to modules/opsrule/opsrule.k index 6e48093..d1f14c4 100644 --- a/models/schema/v1/trait/opsrule.k +++ b/modules/opsrule/opsrule.k @@ -10,9 +10,22 @@ schema OpsRule: Examples -------- - import catalog.models.schema.v1.trait as t + import opsrule as o + import kam.v1.app_configuration + import kam.v1.workload as wl + import kam.v1.workload.container as c - opsRule : t.OpsRule { + helloworld : ac.AppConfiguration { + workload: wl.Service { + containers: { + "nginx": c.Container { + image: "nginx:v1" + } + } + } + } + + opsRule : o.OpsRule { maxUnavailable: "30%" } """ diff --git a/models/generators/Makefile b/modules/opsrule/src/Makefile similarity index 91% rename from models/generators/Makefile rename to modules/opsrule/src/Makefile index d932deb..9ff5d88 100644 --- a/models/generators/Makefile +++ b/modules/opsrule/src/Makefile @@ -2,7 +2,7 @@ TEST?=$$(go list ./... | grep -v 'vendor') ###### chang variables below according to your own modules ### NAMESPACE=kusionstack NAME=opsrule -VERSION=v0.1.0 +VERSION=0.0.1 BINARY=../bin/kusion-module-${NAME}_${VERSION} LOCAL_ARCH := $(shell uname -m) @@ -17,7 +17,7 @@ export OS_ARCH ?= $(GOARCH_LOCAL) default: install build-darwin: - GOOS=darwin GOARCH=arm64 go build -o ${BINARY} ./${NAME} + GOOS=darwin GOARCH=arm64 go build -o ${BINARY} ./ install: build-darwin # copy module binary to $KUSION_HOME. e.g. ~/.kusion/modules/kusionstack/opsrule/v0.1.0/darwin/arm64/kusion-module-opsrule_v0.1.0 diff --git a/models/generators/go.mod b/modules/opsrule/src/go.mod similarity index 74% rename from models/generators/go.mod rename to modules/opsrule/src/go.mod index b624727..36d95d4 100644 --- a/models/generators/go.mod +++ b/modules/opsrule/src/go.mod @@ -1,13 +1,12 @@ -module kusion-modules +module opsrule go 1.22 require ( - gopkg.in/yaml.v2 v2.4.0 k8s.io/apimachinery v0.29.2 kusionstack.io/kube-api v0.1.1 - kusionstack.io/kusion v0.10.1-0.20240319121724-1726f1070bfe - kusionstack.io/kusion-module-framework v0.0.0-20240319125223-dc8cc739460b + kusionstack.io/kusion v0.10.1-0.20240326060146-3f01e9416ff6 + kusionstack.io/kusion-module-framework v0.0.0-20240326063408-807a5a4e4682 ) require ( @@ -16,11 +15,11 @@ require ( github.com/fatih/color v1.13.0 // indirect github.com/go-logr/logr v1.3.0 // indirect github.com/gogo/protobuf v1.3.2 // indirect - github.com/golang/protobuf v1.5.3 // indirect + github.com/golang/protobuf v1.5.4 // indirect github.com/google/go-github/v50 v50.0.0 // indirect github.com/google/go-querystring v1.1.0 // indirect github.com/google/gofuzz v1.2.0 // indirect - github.com/hashicorp/go-hclog v1.5.0 // indirect + github.com/hashicorp/go-hclog v0.16.2 // indirect github.com/hashicorp/go-plugin v1.6.0 // indirect github.com/hashicorp/go-version v1.6.0 // indirect github.com/hashicorp/yamux v0.1.1 // indirect @@ -36,17 +35,18 @@ require ( go.uber.org/atomic v1.9.0 // indirect go.uber.org/multierr v1.6.0 // indirect go.uber.org/zap v1.24.0 // indirect - golang.org/x/crypto v0.17.0 // indirect - golang.org/x/net v0.19.0 // indirect - golang.org/x/oauth2 v0.14.0 // indirect - golang.org/x/sys v0.15.0 // indirect + golang.org/x/crypto v0.18.0 // indirect + golang.org/x/net v0.20.0 // indirect + golang.org/x/oauth2 v0.16.0 // indirect + golang.org/x/sys v0.16.0 // indirect golang.org/x/text v0.14.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20231106174013-bbf56f31fb17 // indirect - google.golang.org/grpc v1.61.1 // indirect - google.golang.org/protobuf v1.32.0 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240123012728-ef4313101c80 // indirect + google.golang.org/grpc v1.62.0 // indirect + google.golang.org/protobuf v1.33.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect + gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect k8s.io/api v0.29.2 // indirect k8s.io/klog/v2 v2.110.1 // indirect diff --git a/modules/opsrule/src/go.sum b/modules/opsrule/src/go.sum new file mode 100644 index 0000000..7b4d72f --- /dev/null +++ b/modules/opsrule/src/go.sum @@ -0,0 +1,222 @@ +github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= +github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= +github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8= +github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= +github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM= +github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= +github.com/bufbuild/protocompile v0.4.0 h1:LbFKd2XowZvQ/kajzguUp2DC9UEIQhIq77fZZlaQsNA= +github.com/bufbuild/protocompile v0.4.0/go.mod h1:3v93+mbWn/v3xzN+31nwkJfrEpAUwp+BagBSZWx+TP8= +github.com/bytedance/mockey v1.2.10 h1:4JlMpkm7HMXmTUtItid+iCu2tm61wvq+ca1X2u7ymzE= +github.com/bytedance/mockey v1.2.10/go.mod h1:bNrUnI1u7+pAc0TYDgPATM+wF2yzHxmNH+iDXg4AOCU= +github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= +github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= +github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= +github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w= +github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= +github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY= +github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= +github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= +github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= +github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= +github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= +github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= +github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= +github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= +github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= +github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-github/v50 v50.0.0 h1:gdO1AeuSZZK4iYWwVbjni7zg8PIQhp7QfmPunr016Jk= +github.com/google/go-github/v50 v50.0.0/go.mod h1:Ev4Tre8QoKiolvbpOSG3FIi4Mlon3S2Nt9W5JYqKiwA= +github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8= +github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU= +github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= +github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/google/pprof v0.0.0-20211214055906-6f57359322fd h1:1FjCyPC+syAzJ5/2S8fqdZK1R22vvA0J7JZKcuOIQ7Y= +github.com/google/pprof v0.0.0-20211214055906-6f57359322fd/go.mod h1:KgnwoLYCZ8IQu3XUZ8Nc/bM9CCZFOyjUNOSygVozoDg= +github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1 h1:EGx4pi6eqNxGaHF6qqu48+N2wcFQ5qg5FXgOdqsJ5d8= +github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= +github.com/hashicorp/go-hclog v0.16.2 h1:K4ev2ib4LdQETX5cSZBG0DVLk1jwGqSPXBjdah3veNs= +github.com/hashicorp/go-hclog v0.16.2/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ= +github.com/hashicorp/go-plugin v1.6.0 h1:wgd4KxHJTVGGqWBq4QPB1i5BZNEx9BR8+OFmHDmTk8A= +github.com/hashicorp/go-plugin v1.6.0/go.mod h1:lBS5MtSSBZk0SHc66KACcjjlU6WzEVP/8pwz68aMkCI= +github.com/hashicorp/go-version v1.6.0 h1:feTTfFNnjP967rlCxM/I9g701jU+RN74YKx2mOkIeek= +github.com/hashicorp/go-version v1.6.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= +github.com/hashicorp/yamux v0.1.1 h1:yrQxtgseBDrq9Y652vSRDvsKCJKOUD+GzTS4Y0Y8pvE= +github.com/hashicorp/yamux v0.1.1/go.mod h1:CtWFDAQgb7dxtzFs4tWbplKIe2jSi3+5vKbgIO0SLnQ= +github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= +github.com/jhump/protoreflect v1.15.1/go.mod h1:jD/2GMKKE6OqX8qTjhADU1e6DShO+gavG9e0Q693nKo= +github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= +github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= +github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo= +github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= +github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= +github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= +github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= +github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= +github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= +github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= +github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= +github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= +github.com/mattn/go-colorable v0.1.12 h1:jF+Du6AlPIjs2BiUiQlKOX0rt3SujHxPnksPKZbaA40= +github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= +github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= +github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84= +github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= +github.com/mattn/go-isatty v0.0.14 h1:yVuAays6BHfxijgZPzw+3Zlu5yQgKGP2/hcQbHb7S9Y= +github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= +github.com/mitchellh/go-testing-interface v1.14.1 h1:jrgshOhYAUVNMAJiKbEu7EqAwgJJ2JqpQmpLJOu07cU= +github.com/mitchellh/go-testing-interface v1.14.1/go.mod h1:gfgS7OtZj6MA4U1UrDRp04twqAjfvlZyCfX3sDjEym8= +github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= +github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/oklog/run v1.0.0 h1:Ru7dDtJNOyC66gQ5dQmaCa0qIsAUFY3sFpK1Xk8igrw= +github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= +github.com/onsi/ginkgo/v2 v2.13.0 h1:0jY9lJquiL8fcf3M4LAXN5aMlS/b2BV86HFFPCPMgE4= +github.com/onsi/ginkgo/v2 v2.13.0/go.mod h1:TE309ZR8s5FsKKpuB1YAQYBzCaAfUgatB/xlT/ETL/o= +github.com/onsi/gomega v1.30.0 h1:hvMK7xYz4D3HapigLTeGdId/NcfQx1VHMJc60ew99+8= +github.com/onsi/gomega v1.30.0/go.mod h1:9sxs+SwGrKI0+PWe4Fxa9tFQQBG5xSsSbMXOI8PPpoQ= +github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= +github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= +github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= +github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= +github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= +github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d h1:zE9ykElWQ6/NYmHa3jpm/yHnI4xSofP+UP6SpjHcSeM= +github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= +github.com/smartystreets/goconvey v1.6.4 h1:fv0U8FUIMPNf1L9lnHLvLhgicrIVChEkdzIKYqbNC9s= +github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= +github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= +github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= +github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= +github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= +github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= +github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= +go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= +go.uber.org/atomic v1.9.0 h1:ECmE8Bn/WFTYwEW/bpKD3M8VtR/zQVbavAoalC1PYyE= +go.uber.org/atomic v1.9.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= +go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A= +go.uber.org/goleak v1.2.1/go.mod h1:qlT2yGI9QafXHhZZLxlSuNsMw3FFLxBr+tBRlmO1xH4= +go.uber.org/multierr v1.6.0 h1:y6IPFStTAIT5Ytl7/XYmHvzXQ7S3g/IeZW9hyZ5thw4= +go.uber.org/multierr v1.6.0/go.mod h1:cdWPpRnG4AhwMwsgIHip0KRBQjJy5kYEpYjJxpXp9iU= +go.uber.org/zap v1.24.0 h1:FiJd5l1UOLj0wCgbSE0rwwXHzEdAZS6hiiSnxJN/D60= +go.uber.org/zap v1.24.0/go.mod h1:2kMP+WWQ8aoFoedH3T2sq6iJ2yDWpHbP0f6MQbS9Gkg= +golang.org/x/arch v0.1.0 h1:oMxhUYsO9VsR1dcoVUjJjIGhx1LXol3989T/yZ59Xsw= +golang.org/x/arch v0.1.0/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8= +golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= +golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= +golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= +golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= +golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= +golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= +golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.20.0 h1:aCL9BSgETF1k+blQaYUBx9hJ9LOGP3gAVemcZlf1Kpo= +golang.org/x/net v0.20.0/go.mod h1:z8BVo6PvndSri0LbOE3hAn0apkU+1YvI6E70E9jsnvY= +golang.org/x/oauth2 v0.16.0 h1:aDkGMBSYxElaoP81NpoUoz2oo2R2wHdZpGToUxfyQrQ= +golang.org/x/oauth2 v0.16.0/go.mod h1:hqZ+0LWXsiVoZpeld6jVt06P3adbS2Uu911W1SsJv2o= +golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= +golang.org/x/sys v0.16.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= +golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= +golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= +golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= +golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= +golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= +golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= +golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= +golang.org/x/tools v0.16.1 h1:TLyB3WofjdOEepBHAU20JdNC1Zbg87elYofWYAY5oZA= +golang.org/x/tools v0.16.1/go.mod h1:kYVVN6I1mBNoB1OX+noeBjbRk4IUEPa7JJ+TJMEooJ0= +golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +google.golang.org/appengine v1.6.8 h1:IhEN5q69dyKagZPYMSdIjS2HqprW324FRQZJcGqPAsM= +google.golang.org/appengine v1.6.8/go.mod h1:1jJ3jBArFh5pcgW8gCtRJnepW8FzD1V44FJffLiz/Ds= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240123012728-ef4313101c80 h1:AjyfHzEPEFp/NpvfN5g+KDla3EMojjhRVZc1i7cj+oM= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240123012728-ef4313101c80/go.mod h1:PAREbraiVEVGVdTZsVWjSbbTtSyGbAgIIvni8a8CD5s= +google.golang.org/grpc v1.62.0 h1:HQKZ/fa1bXkX1oFOvSjmZEUL8wLSaZTjCcLAlmZRtdk= +google.golang.org/grpc v1.62.0/go.mod h1:IWTG0VlJLCh1SkC58F7np9ka9mx/WNkjl4PGJaiq+QE= +google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= +google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI= +google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= +gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= +gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= +gopkg.in/natefinch/lumberjack.v2 v2.0.0 h1:1Lc07Kr7qY4U2YPouBjpCLxpiyxIVoxqXgkXLknAOE8= +gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k= +gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= +gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= +gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +k8s.io/api v0.29.2 h1:hBC7B9+MU+ptchxEqTNW2DkUosJpp1P+Wn6YncZ474A= +k8s.io/api v0.29.2/go.mod h1:sdIaaKuU7P44aoyyLlikSLayT6Vb7bvJNCX105xZXY0= +k8s.io/apimachinery v0.29.2 h1:EWGpfJ856oj11C52NRCHuU7rFDwxev48z+6DSlGNsV8= +k8s.io/apimachinery v0.29.2/go.mod h1:6HVkd1FwxIagpYrHSwJlQqZI3G9LfYWRPAkUvLnXTKU= +k8s.io/klog/v2 v2.110.1 h1:U/Af64HJf7FcwMcXyKm2RPM22WZzyR7OSpYj5tg3cL0= +k8s.io/klog/v2 v2.110.1/go.mod h1:YGtd1984u+GgbuZ7e08/yBuAfKLSO0+uR1Fhi6ExXjo= +k8s.io/utils v0.0.0-20230726121419-3b25d923346b h1:sgn3ZU783SCgtaSJjpcVVlRqd6GSnlTLKgpAAttJvpI= +k8s.io/utils v0.0.0-20230726121419-3b25d923346b/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +kcl-lang.io/kcl-plugin v0.5.0 h1:eoh6y4l81rwA8yhJXU4hN7YmJeTUNB1nfYCP9OffSxc= +kcl-lang.io/kcl-plugin v0.5.0/go.mod h1:QnZ5OLcyBw5nOnHpChRHtvBq8wvjwiHu/ZZ8j1dfz48= +kusionstack.io/kube-api v0.1.1 h1:ieoZhaUfK78hsyQ7GsU6ZuxBAcVU+ZuKs7vedGkO8sI= +kusionstack.io/kube-api v0.1.1/go.mod h1:QIQrH+MK9xuV+mXCAkk6DN8z6b8oyf4XN0VRccmHH/k= +kusionstack.io/kusion v0.10.1-0.20240326060146-3f01e9416ff6 h1:66DJEK1NZyA7C/Geh9f2MCeZx54R5y6quHJXWpoxJX4= +kusionstack.io/kusion v0.10.1-0.20240326060146-3f01e9416ff6/go.mod h1:xI/6cDT0cZAaWFdKVnpV/U5TKpSQnLMnUJAEy/uRpL8= +kusionstack.io/kusion-module-framework v0.0.0-20240326063408-807a5a4e4682 h1:X8zSDNh5Sa6FsTbwgohdu6tQ9lDQ3lZs9mTnXvk9GYo= +kusionstack.io/kusion-module-framework v0.0.0-20240326063408-807a5a4e4682/go.mod h1:ynITUHw3Cke7aLhzQXXFvXgxQcLF/z4uFxn8O87K4mA= +sigs.k8s.io/controller-runtime v0.15.1 h1:9UvgKD4ZJGcj24vefUFgZFP3xej/3igL9BsOUTb/+4c= +sigs.k8s.io/controller-runtime v0.15.1/go.mod h1:7ngYvp1MLT+9GeZ+6lH3LOlcHkp/+tzA/fmHa4iq9kk= +sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= +sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= +sigs.k8s.io/structured-merge-diff/v4 v4.4.1 h1:150L+0vs/8DA78h1u02ooW1/fFq/Lwr+sGiqlzvrtq4= +sigs.k8s.io/structured-merge-diff/v4 v4.4.1/go.mod h1:N8hJocpFajUSSeSJ9bOZ77VzejKZaXsTtZo4/u7Io08= +sigs.k8s.io/yaml v1.3.0 h1:a2VclLzOGrwOHDiV8EfBGhvjHvP46CtW5j6POvhYGGo= +sigs.k8s.io/yaml v1.3.0/go.mod h1:GeOyir5tyXNByN85N/dRIT9es5UQNerPYEKK56eTBm8= diff --git a/models/generators/opsrule/opsrule.go b/modules/opsrule/src/opsrule.go similarity index 100% rename from models/generators/opsrule/opsrule.go rename to modules/opsrule/src/opsrule.go diff --git a/models/generators/opsrule/opsrule_test.go b/modules/opsrule/src/opsrule_test.go similarity index 99% rename from models/generators/opsrule/opsrule_test.go rename to modules/opsrule/src/opsrule_test.go index 2437bf8..c994df6 100644 --- a/models/generators/opsrule/opsrule_test.go +++ b/modules/opsrule/src/opsrule_test.go @@ -5,7 +5,6 @@ import ( "reflect" "testing" - "gopkg.in/yaml.v2" "kusionstack.io/kusion-module-framework/pkg/module" v1 "kusionstack.io/kusion/pkg/apis/core/v1" "kusionstack.io/kusion/pkg/apis/core/v1/workload" diff --git a/models/schema/v1/accessories/postgres.k b/modules/postgres/postgres.k similarity index 100% rename from models/schema/v1/accessories/postgres.k rename to modules/postgres/postgres.k diff --git a/models/samples/hellocollaset/base/base.k b/samples/hellocollaset/base/base.k similarity index 100% rename from models/samples/hellocollaset/base/base.k rename to samples/hellocollaset/base/base.k diff --git a/models/samples/hellocollaset/prod/kcl.yaml b/samples/hellocollaset/prod/kcl.yaml similarity index 100% rename from models/samples/hellocollaset/prod/kcl.yaml rename to samples/hellocollaset/prod/kcl.yaml diff --git a/models/samples/hellocollaset/prod/main.k b/samples/hellocollaset/prod/main.k similarity index 100% rename from models/samples/hellocollaset/prod/main.k rename to samples/hellocollaset/prod/main.k diff --git a/models/samples/hellocollaset/prod/stack.yaml b/samples/hellocollaset/prod/stack.yaml similarity index 100% rename from models/samples/hellocollaset/prod/stack.yaml rename to samples/hellocollaset/prod/stack.yaml diff --git a/models/samples/hellocollaset/project.yaml b/samples/hellocollaset/project.yaml similarity index 100% rename from models/samples/hellocollaset/project.yaml rename to samples/hellocollaset/project.yaml diff --git a/models/samples/helloworld/base/base.k b/samples/helloworld/base/base.k similarity index 100% rename from models/samples/helloworld/base/base.k rename to samples/helloworld/base/base.k diff --git a/models/samples/helloworld/prod/kcl.yaml b/samples/helloworld/prod/kcl.yaml similarity index 100% rename from models/samples/helloworld/prod/kcl.yaml rename to samples/helloworld/prod/kcl.yaml diff --git a/models/samples/helloworld/prod/main.k b/samples/helloworld/prod/main.k similarity index 100% rename from models/samples/helloworld/prod/main.k rename to samples/helloworld/prod/main.k diff --git a/models/samples/helloworld/prod/stack.yaml b/samples/helloworld/prod/stack.yaml similarity index 100% rename from models/samples/helloworld/prod/stack.yaml rename to samples/helloworld/prod/stack.yaml diff --git a/models/samples/helloworld/project.yaml b/samples/helloworld/project.yaml similarity index 100% rename from models/samples/helloworld/project.yaml rename to samples/helloworld/project.yaml diff --git a/models/samples/pgadmin/base/base.k b/samples/pgadmin/base/base.k similarity index 100% rename from models/samples/pgadmin/base/base.k rename to samples/pgadmin/base/base.k diff --git a/models/samples/pgadmin/prod/kcl.yaml b/samples/pgadmin/prod/kcl.yaml similarity index 100% rename from models/samples/pgadmin/prod/kcl.yaml rename to samples/pgadmin/prod/kcl.yaml diff --git a/models/samples/pgadmin/prod/main.k b/samples/pgadmin/prod/main.k similarity index 100% rename from models/samples/pgadmin/prod/main.k rename to samples/pgadmin/prod/main.k diff --git a/models/samples/pgadmin/prod/stack.yaml b/samples/pgadmin/prod/stack.yaml similarity index 100% rename from models/samples/pgadmin/prod/stack.yaml rename to samples/pgadmin/prod/stack.yaml diff --git a/models/samples/pgadmin/project.yaml b/samples/pgadmin/project.yaml similarity index 100% rename from models/samples/pgadmin/project.yaml rename to samples/pgadmin/project.yaml diff --git a/models/samples/prometheus/base/base.k b/samples/prometheus/base/base.k similarity index 100% rename from models/samples/prometheus/base/base.k rename to samples/prometheus/base/base.k diff --git a/models/samples/prometheus/prod/kcl.yaml b/samples/prometheus/prod/kcl.yaml similarity index 100% rename from models/samples/prometheus/prod/kcl.yaml rename to samples/prometheus/prod/kcl.yaml diff --git a/models/samples/prometheus/prod/main.k b/samples/prometheus/prod/main.k similarity index 100% rename from models/samples/prometheus/prod/main.k rename to samples/prometheus/prod/main.k diff --git a/models/samples/prometheus/prod/stack.yaml b/samples/prometheus/prod/stack.yaml similarity index 100% rename from models/samples/prometheus/prod/stack.yaml rename to samples/prometheus/prod/stack.yaml diff --git a/models/samples/prometheus/project.yaml b/samples/prometheus/project.yaml similarity index 100% rename from models/samples/prometheus/project.yaml rename to samples/prometheus/project.yaml diff --git a/models/samples/samplejob/base/base.k b/samples/samplejob/base/base.k similarity index 100% rename from models/samples/samplejob/base/base.k rename to samples/samplejob/base/base.k diff --git a/models/samples/samplejob/prod/kcl.yaml b/samples/samplejob/prod/kcl.yaml similarity index 100% rename from models/samples/samplejob/prod/kcl.yaml rename to samples/samplejob/prod/kcl.yaml diff --git a/models/samples/samplejob/prod/main.k b/samples/samplejob/prod/main.k similarity index 100% rename from models/samples/samplejob/prod/main.k rename to samples/samplejob/prod/main.k diff --git a/models/samples/samplejob/prod/stack.yaml b/samples/samplejob/prod/stack.yaml similarity index 100% rename from models/samples/samplejob/prod/stack.yaml rename to samples/samplejob/prod/stack.yaml diff --git a/models/samples/samplejob/project.yaml b/samples/samplejob/project.yaml similarity index 100% rename from models/samples/samplejob/project.yaml rename to samples/samplejob/project.yaml diff --git a/models/samples/wordpress/base/base.k b/samples/wordpress/base/base.k similarity index 100% rename from models/samples/wordpress/base/base.k rename to samples/wordpress/base/base.k diff --git a/models/samples/wordpress/prod/kcl.yaml b/samples/wordpress/prod/kcl.yaml similarity index 100% rename from models/samples/wordpress/prod/kcl.yaml rename to samples/wordpress/prod/kcl.yaml diff --git a/models/samples/wordpress/prod/main.k b/samples/wordpress/prod/main.k similarity index 100% rename from models/samples/wordpress/prod/main.k rename to samples/wordpress/prod/main.k diff --git a/models/samples/wordpress/prod/stack.yaml b/samples/wordpress/prod/stack.yaml similarity index 100% rename from models/samples/wordpress/prod/stack.yaml rename to samples/wordpress/prod/stack.yaml diff --git a/models/samples/wordpress/project.yaml b/samples/wordpress/project.yaml similarity index 100% rename from models/samples/wordpress/project.yaml rename to samples/wordpress/project.yaml