API Reference

Packages

appstudio.redhat.com/v1alpha1

Package v1alpha1 contains API Schema definitions for the appstudio v1alpha1 API group

Resource Types

Application

Application is the Schema for the applications API. For a detailed description with examples, refer to Hybrid Application Service Kube API

Appears in:

Field Description
apiVersion string appstudio.redhat.com/v1alpha1
kind string Application
metadata ObjectMeta Refer to Kubernetes API documentation for fields of metadata.
spec ApplicationSpec  

ApplicationGitRepository

ApplicationGitRepository defines a git repository for a given Application resource (either appmodel or gitops)

Appears in:

Field Description
url string URL refers to the repository URL that should be used. If not specified, a GitOps repository under the $GITHUB_ORG (defaults to redhat-appstudio-appdata) organization on GitHub will be generated by HAS. Example: https://github.com/devfile-test/myrepo. Required.
branch string Branch corresponds to the branch in the repository that should be used Example: devel. Optional.
context string Context corresponds to the context within the repository that should be used Example: folderA/folderB/gitops. Optional.

ApplicationList

ApplicationList contains a list of Application

Field Description
apiVersion string appstudio.redhat.com/v1alpha1
kind string ApplicationList
metadata ListMeta Refer to Kubernetes API documentation for fields of metadata.
items Application array  

ApplicationSpec

ApplicationSpec defines the desired state of Application

Appears in:

Field Description
displayName string DisplayName refers to the name that an application will be deployed with in App Studio. Required.
appModelRepository ApplicationGitRepository AppModelRepository refers to the git repository that will store the application model (a devfile) Can be the same as GitOps repository. A repository will be generated if this field is left blank. Optional.
gitOpsRepository ApplicationGitRepository GitOpsRepository refers to the git repository that will store the gitops resources. Can be the same as App Model Repository. A repository will be generated if this field is left blank. Optional.
description string Description refers to a brief description of the application. Optional.

Component

Component is the Schema for the components API. For a detailed description with examples, refer to Hybrid Application Service Kube API

Appears in:

Field Description
apiVersion string appstudio.redhat.com/v1alpha1
kind string Component
metadata ObjectMeta Refer to Kubernetes API documentation for fields of metadata.
spec ComponentSpec  

ComponentDetectionDescription

ComponentDetectionDescription holds all the information about the component being detected

Appears in:

Field Description
devfileFound boolean DevfileFound tells if a devfile is found in the component
language string Language specifies the language of the component detected Example: JavaScript
projectType string ProjectType specifies the type of project for the component detected Example Node.JS
componentStub ComponentSpec ComponentStub is a stub of the component detected with all the info gathered from the devfile or service detection

ComponentDetectionQuery

ComponentDetectionQuery is the Schema for the componentdetectionqueries API. For a detailed description with examples, refer to Hybrid Application Service Kube API

Appears in:

Field Description
apiVersion string appstudio.redhat.com/v1alpha1
kind string ComponentDetectionQuery
metadata ObjectMeta Refer to Kubernetes API documentation for fields of metadata.
spec ComponentDetectionQuerySpec  

ComponentDetectionQueryList

ComponentDetectionQueryList contains a list of ComponentDetectionQuery

Field Description
apiVersion string appstudio.redhat.com/v1alpha1
kind string ComponentDetectionQueryList
metadata ListMeta Refer to Kubernetes API documentation for fields of metadata.
items ComponentDetectionQuery array  

ComponentDetectionQuerySpec

ComponentDetectionQuerySpec defines the desired state of ComponentDetectionQuery

Appears in:

Field Description
git GitSource Git Source for a Component. Required.
secret string Secret describes the name of an optional Kubernetes secret containing a Personal Access Token to access the git repostiory. Optional.
generateComponentName boolean It defines if should generate random characters at the end of the component name instead of a predicted default value The default value is false. If the value is set to true, component name will always have random characters appended Optional.

ComponentList

ComponentList contains a list of Component

Field Description
apiVersion string appstudio.redhat.com/v1alpha1
kind string ComponentList
metadata ListMeta Refer to Kubernetes API documentation for fields of metadata.
items Component array  

ComponentSource

ComponentSource describes the Component source

Appears in:

Field Description
ComponentSourceUnion ComponentSourceUnion  

ComponentSourceUnion

Appears in:

Field Description
git GitSource Git Source for a Component. Optional.

ComponentSpec

ComponentSpec defines the desired state of Component

Appears in:

Field Description
componentName string ComponentName is name of the component to be added to the Application. The name must adhere to DNS-1123 validation. Required.
application string Application is the name of the application resource that the component belongs to. Required.
secret string Secret describes the name of a Kubernetes secret containing either: 1. A Personal Access Token to access the Component’s git repostiory (if using a Git-source component) or 2. An Image Pull Secret to access the Component’s container image (if using an Image-source component). Optional.
source ComponentSource Source describes the Component source. Optional.
resources ResourceRequirements Compute Resources required by this component. Optional.
replicas integer The number of replicas to deploy the component with. Optional.
targetPort integer The port to expose the component over. Optional.
route string The route to expose the component with. Optional.
env EnvVar array An array of environment variables to add to the component (ValueFrom not currently supported) Optional
containerImage string The container image to build or create the component from Example: quay.io/someorg/somerepository:latest. Optional.
skipGitOpsResourceGeneration boolean Whether or not to bypass the generation of GitOps resources for the Component. Defaults to false. Optional.
build-nudges-ref string array The list of components to be nudged by this components build upon a successful result. Optional.

GitOpsStatus

GitOpsStatus contains GitOps repository-specific status for the component

Appears in:

Field Description
repositoryURL string RepositoryURL is the gitops repository URL for the component
branch string Branch is the git branch used for the gitops repository
context string Context is the path within the gitops repository used for the gitops resources
resourceGenerationSkipped boolean ResourceGenerationSkipped is whether or not GitOps resource generation was skipped for the component
commitID string CommitID is the most recent commit ID in the GitOps repository for this component

GitSource

Appears in:

Field Description
url string An HTTPS URL representing the git repository to create the component from.
revision string Specify a branch/tag/commit id. If not specified, default is main/master. Example: devel. Optional.
context string A relative path inside the git repo containing the component Example: folderA/folderB/gitops. Optional.
devfileUrl string If specified, the devfile at the URI will be used for the component. Can be a local path inside the repository, or an external URL. Example: https://raw.githubusercontent.com/devfile-samples/devfile-sample-java-springboot-basic/main/devfile.yaml. Optional.
dockerfileUrl string If specified, the dockerfile at the URI will be used for the component. Can be a local path inside the repository, or an external URL. Optional.

Snapshot

Snapshot is the Schema for the snapshots API

Appears in:

Field Description
apiVersion string appstudio.redhat.com/v1alpha1
kind string Snapshot
metadata ObjectMeta Refer to Kubernetes API documentation for fields of metadata.
spec SnapshotSpec  

SnapshotArtifacts

SnapshotArtifacts is a placeholder section for ‘artifact links’ we want to maintain to other AppStudio resources. For example: here I’m imagining we might want to keep track of container image <=> (source code repo, commit sha) links, Which might be useful to present to the user within the UI.

Appears in:

Field Description
unstableFields JSON NOTE: This field (and struct) are placeholders. - Until this API is stabilized, consumers of the API may store any unstructured JSON/YAML data here, but no backwards compatibility will be preserved.

SnapshotComponent

SnapshotComponent

Appears in:

Field Description
name string Name is the name of the component
containerImage string ContainerImage is the container image to use when deploying the component, as part of a Snapshot
source ComponentSource Source describes the Component source. Optional.

SnapshotList

SnapshotList contains a list of Snapshot

Field Description
apiVersion string appstudio.redhat.com/v1alpha1
kind string SnapshotList
metadata ListMeta Refer to Kubernetes API documentation for fields of metadata.
items Snapshot array  

SnapshotSpec

SnapshotSpec defines the desired state of Snapshot

Appears in:

Field Description
application string Application is a reference to the name of an Application resource within the same namespace, which defines the target application for the Snapshot (when used with a Binding).
displayName string DisplayName is a user-visible, user-definable name for the resource (and is not used for any functional behaviour)
displayDescription string DisplayDescription is a user-visible, user definable description for the resource (and is not used for any functional behaviour)
components SnapshotComponent array Components field contains the sets of components to deploy as part of this snapshot.
artifacts SnapshotArtifacts Artifacts is a placeholder section for ‘artifact links’ we want to maintain to other AppStudio resources. See Environment API doc for details.