infisical
Fetch and work with secrets for your dagger application using Infisical.Installation
dagger install github.com/jpadams/infisical-dagger@8af6331e6e9c9bb901fd3b8eeff1692d3eea85d9
Entrypoint
Return Type
Infisical !
Arguments
Name | Type | Description |
---|---|---|
apiUrl | String ! | Your self-hosted Infisical site URL. Default: https://app.infisical.com. |
accessToken | String ! | Your self-hosted Infisical site URL. Default: https://app.infisical.com. |
Example
dagger -m github.com/jpadams/infisical-dagger@8af6331e6e9c9bb901fd3b8eeff1692d3eea85d9 call \
--api-url string --access-token string
func (m *myModule) example(apiUrl string, accessToken string) *Infisical {
return dag.
Infisical(apiUrl, accessToken)
}
@function
def example(api_url: str, access_token: str) -> dag.Infisical:
return (
dag.infisical(api_url, access_token)
)
@func()
example(apiUrl: string, accessToken: string): Infisical {
return dag
.infisical(apiUrl, accessToken)
}
Types
Infisical 🔗
withUniversalAuth() 🔗
Authenticate with Universal Auth
Return Type
Infisical !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
clientId | Secret ! | - | Your Machine Identity Client ID |
clientSecret | Secret ! | - | Your Machine Identity Client Secret. |
Example
dagger -m github.com/jpadams/infisical-dagger@8af6331e6e9c9bb901fd3b8eeff1692d3eea85d9 call \
--api-url string --access-token string with-universal-auth --client-id env:MYSECRET --client-secret env:MYSECRET
func (m *myModule) example(apiUrl string, accessToken string, clientId *Secret, clientSecret *Secret) *Infisical {
return dag.
Infisical(apiUrl, accessToken).
WithUniversalAuth(clientId, clientSecret)
}
@function
def example(api_url: str, access_token: str, client_id: dagger.Secret, client_secret: dagger.Secret) -> dag.Infisical:
return (
dag.infisical(api_url, access_token)
.with_universal_auth(client_id, client_secret)
)
@func()
example(apiUrl: string, accessToken: string, clientId: Secret, clientSecret: Secret): Infisical {
return dag
.infisical(apiUrl, accessToken)
.withUniversalAuth(clientId, clientSecret)
}
getSecretByName() 🔗
Get a secret by name
Return Type
Secret !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
secretName | String ! | - | The name of the secret to get. |
projectId | String ! | - | The ID of the project to get the secret from. |
environmentSlug | String ! | - | The slug of the environment to get the secret from. |
secretPath | String ! | - | The path of the secret to get. |
expandSecretReferences | Boolean ! | true | Whether or not to expand secret references |
includeImports | Boolean ! | true | Weather to include imported secrets or not. |
Example
dagger -m github.com/jpadams/infisical-dagger@8af6331e6e9c9bb901fd3b8eeff1692d3eea85d9 call \
--api-url string --access-token string get-secret-by-name --secret-name string --project-id string --environment-slug string --secret-path string --expand-secret-references boolean --include-imports boolean
func (m *myModule) example(apiUrl string, accessToken string, secretName string, projectId string, environmentSlug string, secretPath string, expandSecretReferences bool, includeImports bool) *Secret {
return dag.
Infisical(apiUrl, accessToken).
GetSecretByName(secretName, projectId, environmentSlug, secretPath, expandSecretReferences, includeImports)
}
@function
def example(api_url: str, access_token: str, secret_name: str, project_id: str, environment_slug: str, secret_path: str, expand_secret_references: bool, include_imports: bool) -> dagger.Secret:
return (
dag.infisical(api_url, access_token)
.get_secret_by_name(secret_name, project_id, environment_slug, secret_path, expand_secret_references, include_imports)
)
@func()
example(apiUrl: string, accessToken: string, secretName: string, projectId: string, environmentSlug: string, secretPath: string, expandSecretReferences: boolean, includeImports: boolean): Secret {
return dag
.infisical(apiUrl, accessToken)
.getSecretByName(secretName, projectId, environmentSlug, secretPath, expandSecretReferences, includeImports)
}
getSecrets() 🔗
List secrets
Return Type
[Secret ! ] !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
projectId | String ! | - | The ID of the project to get the secret from. |
environmentSlug | String ! | - | The slug of the environment to get the secret from. |
secretPath | String ! | - | The path of the secret to get. |
expandSecretReferences | Boolean ! | true | Whether or not to expand secret references |
recursive | Boolean ! | false | Whether or not to fetch all secrets from the specified base path, and all of its subdirectories. Note, the max depth is 20 deep. |
includeImports | Boolean ! | true | Weather to include imported secrets or not. |
tagFilters | [String ! ] ! | [] | No description provided |
Example
dagger -m github.com/jpadams/infisical-dagger@8af6331e6e9c9bb901fd3b8eeff1692d3eea85d9 call \
--api-url string --access-token string get-secrets --project-id string --environment-slug string --secret-path string --expand-secret-references boolean --recursive boolean --include-imports boolean --tag-filters string1 --tag-filters string2
func (m *myModule) example(apiUrl string, accessToken string, projectId string, environmentSlug string, secretPath string, expandSecretReferences bool, recursive bool, includeImports bool, tagFilters []string) []*Secret {
return dag.
Infisical(apiUrl, accessToken).
GetSecrets(projectId, environmentSlug, secretPath, expandSecretReferences, recursive, includeImports, tagFilters)
}
@function
def example(api_url: str, access_token: str, project_id: str, environment_slug: str, secret_path: str, expand_secret_references: bool, recursive: bool, include_imports: bool, tag_filters: List[str]) -> List[dagger.Secret]:
return (
dag.infisical(api_url, access_token)
.get_secrets(project_id, environment_slug, secret_path, expand_secret_references, recursive, include_imports, tag_filters)
)
@func()
example(apiUrl: string, accessToken: string, projectId: string, environmentSlug: string, secretPath: string, expandSecretReferences: boolean, recursive: boolean, includeImports: boolean, tagFilters: string[]): Secret[] {
return dag
.infisical(apiUrl, accessToken)
.getSecrets(projectId, environmentSlug, secretPath, expandSecretReferences, recursive, includeImports, tagFilters)
}