Dagger
Search

k6

Module to run k6 QA tests

Installation

dagger install github.com/prefapp/daggerverse/k6@1aa1dec90e31f4fb3d553b8c4246274cd0aecb14

Entrypoint

Return Type
K6
Example
dagger -m github.com/prefapp/daggerverse/k6@1aa1dec90e31f4fb3d553b8c4246274cd0aecb14 call \
func (m *myModule) example() *K6  {
	return dag.
			K6()
}
@function
def example() -> dag.K6:
	return (
		dag.k6()
	)
@func()
example(): K6 {
	return dag
		.k6()
}

Types

K6 🔗

run() 🔗

Runs the k6 QA tests

Return Type
Container !
Arguments
NameTypeDefault ValueDescription
workingDirDirectory !-The working directory containing the script
scriptString !-k6 Script file to execute
env[String ! ] -Environment variables to set
vusInteger 1Virtual users to emulate
durationString "1s"Duration of the test
Example
dagger -m github.com/prefapp/daggerverse/k6@1aa1dec90e31f4fb3d553b8c4246274cd0aecb14 call \
 run --working-dir DIR_PATH --script string
func (m *myModule) example(workingDir *Directory, script string) *Container  {
	return dag.
			K6().
			Run(workingDir, script)
}
@function
def example(working_dir: dagger.Directory, script: str) -> dagger.Container:
	return (
		dag.k6()
		.run(working_dir, script)
	)
@func()
example(workingDir: Directory, script: string): Container {
	return dag
		.k6()
		.run(workingDir, script)
}