mirror of
https://github.com/hauler-dev/hauler.git
synced 2026-04-07 03:07:09 +00:00
18 lines
381 B
Go
18 lines
381 B
Go
package memory
|
|
|
|
import "hauler.dev/go/hauler/pkg/artifacts"
|
|
|
|
type Option func(*Memory)
|
|
|
|
func WithConfig(obj interface{}, mediaType string) Option {
|
|
return func(m *Memory) {
|
|
m.config = artifacts.ToConfig(obj, artifacts.WithConfigMediaType(mediaType))
|
|
}
|
|
}
|
|
|
|
func WithAnnotations(annotations map[string]string) Option {
|
|
return func(m *Memory) {
|
|
m.annotations = annotations
|
|
}
|
|
}
|