name: 'Kubernetes set context'
description: 'Kubernetes set context'
inputs: 
# Used for setting the target K8s cluster context which will be used by other actions like azure/k8s-actions/k8s-deploy or azure/k8s-actions/k8s-create-secret
  cluster-type:
    description: 'Acceptable values: generic or arc'
    required: true
    default: 'generic'
  method:
    description: 'Acceptable values: kubeconfig or service-account or SPN'
    required: true
    default: 'kubeconfig'
  kubeconfig:
    description: 'Kubernetes Config'
    required: false
    default: ''
  context:
    description: 'If your kubeconfig has multiple contexts, use this field to use a specific context, otherwise the default one would be chosen'
    required: false
    default: ''

  k8s-url:
    description: 'Cluster Url'
    required: false
    default: ''
  k8s-secret:
    description: 'Service account secret. Run kubectl get serviceaccounts <service-account-name> -o yaml and copy the service-account-secret-name. Copy the ouptut of kubectl get secret <service-account-secret-name> -o yaml'
    required: false
    default: ''
  
  creds:
    description: 'Azure credentials i.e. output of `az ad sp create-for-rbac --sdk-auth`'
    required: false
    default: ''
  token:
    description: 'Token extracted from the secret of service account (should be base 64 decoded)'
    required: false
    default: ''
  resource-group:
    description: 'Azure resource group name'
    required: false
    default: ''
  cluster-name:
    description: 'Azure connected cluster name'
    required: false
    default: ''
  environment:
    description: 'Name of the environment. Supported values are azurecloud, azurestack, azureusgovernment, azurechinacloud, azuregermancloud. Default being azurecloud'
    required: false
    default: AzureCloud
  
branding:
  color: 'green' # optional, decorates the entry in the GitHub Marketplace
runs:
  using: 'node12'
  main: 'lib/login.js'