Dagger
Search

nixpacks

This module provides a set of functions to build an OCI image from your project using nixpacks.

Installation

dagger install github.com/tsirysndr/daggerverse/nixpacks@9146ad2a58a626996489e7690c0427263ec195b4

Entrypoint

Return Type
Nixpacks
Example
dagger -m github.com/tsirysndr/daggerverse/nixpacks@9146ad2a58a626996489e7690c0427263ec195b4 call \
func (m *myModule) example() *Nixpacks  {
	return dag.
			Nixpacks()
}
@function
def example() -> dag.Nixpacks:
	return (
		dag.nixpacks()
	)
@func()
example(): Nixpacks {
	return dag
		.nixpacks()
}

Types

Nixpacks 🔗

build() 🔗

Build an OCI image from your project using nixpacks

Return Type
String !
Arguments
NameTypeDefault ValueDescription
srcDirectory !-No description provided
nameString !-No description provided
pathString "."No description provided
Example
dagger -m github.com/tsirysndr/daggerverse/nixpacks@9146ad2a58a626996489e7690c0427263ec195b4 call \
 build --src DIR_PATH --name string
func (m *myModule) example(ctx context.Context, src *Directory, name string) string  {
	return dag.
			Nixpacks().
			Build(ctx, src, name)
}
@function
async def example(src: dagger.Directory, name: str) -> str:
	return await (
		dag.nixpacks()
		.build(src, name)
	)
@func()
async example(src: Directory, name: string): Promise<string> {
	return dag
		.nixpacks()
		.build(src, name)
}

plan() 🔗

Generate a plan for building an OCI image from your project using nixpacks

Return Type
File !
Arguments
NameTypeDefault ValueDescription
srcDirectory !-No description provided
pathString "."No description provided
formatString "json"No description provided
Example
dagger -m github.com/tsirysndr/daggerverse/nixpacks@9146ad2a58a626996489e7690c0427263ec195b4 call \
 plan --src DIR_PATH
func (m *myModule) example(src *Directory) *File  {
	return dag.
			Nixpacks().
			Plan(src)
}
@function
def example(src: dagger.Directory) -> dagger.File:
	return (
		dag.nixpacks()
		.plan(src)
	)
@func()
example(src: Directory): File {
	return dag
		.nixpacks()
		.plan(src)
}

dev() 🔗

Return a Container with nixpacks installed

Return Type
Container !
Arguments
NameTypeDefault ValueDescription
srcDirectory -No description provided
Example
dagger -m github.com/tsirysndr/daggerverse/nixpacks@9146ad2a58a626996489e7690c0427263ec195b4 call \
 dev
func (m *myModule) example() *Container  {
	return dag.
			Nixpacks().
			Dev()
}
@function
def example() -> dagger.Container:
	return (
		dag.nixpacks()
		.dev()
	)
@func()
example(): Container {
	return dag
		.nixpacks()
		.dev()
}

publish() 🔗

Publish an OCI image to a registry

Return Type
String !
Arguments
NameTypeDefault ValueDescription
usernameString !-No description provided
passwordSecret !-No description provided
refString !-No description provided
registryString "docker.io"No description provided
Example
dagger -m github.com/tsirysndr/daggerverse/nixpacks@9146ad2a58a626996489e7690c0427263ec195b4 call \
 publish --username string --password env:MYSECRET --ref string
func (m *myModule) example(ctx context.Context, username string, password *Secret, ref string) string  {
	return dag.
			Nixpacks().
			Publish(ctx, username, password, ref)
}
@function
async def example(username: str, password: dagger.Secret, ref: str) -> str:
	return await (
		dag.nixpacks()
		.publish(username, password, ref)
	)
@func()
async example(username: string, password: Secret, ref: string): Promise<string> {
	return dag
		.nixpacks()
		.publish(username, password, ref)
}