#Anyone got an example of using the proxy

1 messages ยท Page 1 of 1 (latest)

terse whale
dull fern
#

I've got that in code, just trying to make it work with a clever little script + shebang

terse whale
#
#!/usr/bin/env dagger

web=$(container | from nginx | with-exposed-port 80)
db=$(container | from postgres | with-exposed-port 5432 | with-env-variable POSTGRES_PASSWORD postgres)

proxy=$(github.com/kpenfound/dagger-modules/proxy |
    with-service $($web | as-service) "web" 80 80 |
    with-service $($db | as-service) "db" 5432 5432
)

$proxy | service | up
#

work for you @dull fern ? ๐Ÿ™‚

dull fern
#

I'll give it a go in the morning, thanks!

terse whale
#

Thanks for this module @toxic plover ๐Ÿ™

toxic plover
#

a classic ๐Ÿ˜„

manic wave
dull fern
#

Slightly related to this: should services binding to services work? Service -> Service -> host?