#general

1 messages ยท Page 1 of 1 (latest)

heavy gazelle
sharp marsh
heavy gazelle
sharp marsh
swift barn
#

somehow the dagger lsp command is not available anymore in 0.2.27

#

It was there in 0.2.26

#

its now cuelsp

winter linden
#

You can call cuelsp directly, it is embedded in dagger only as a convenience

#

We want cuelsp to be useful to all cue developers, whether they use dagger or not. This naming makes that clearer.

swift barn
#

cool. thanks. The vscode extension seems to work also now. ๐Ÿš€

dreamy geode
#

Hey! First of all thanks for your awesome software! Is it possible to push multiple tags with the docker push action or do I have to push using multiple actions?

swift inlet
astral shale
#

Nice work! got the dagger extension and lsp running in vscode.

#

already a huge improvement to DX ๐Ÿ™‚

chilly arch
#

@hereHi everyone, today weโ€™re happy to introduce Dagger for VS Code, with native CUE LSP support. Weโ€™re also open-sourcing our CUE LSP implementation, to make CUE development easier from any text editor or IDE.

Full blog post: https://dagger.io/blog/dagger-vscode
VS Code extension: https://marketplace.visualstudio.com/items?itemName=Dagger.dagger
CUE LSP implementation: https://github.com/dagger/cuelsp

GitHub

Contribute to dagger/cuelsp development by creating an account on GitHub.

#

Special shout-out to @wispy tapir and @swift inlet for all their work on this!

rigid epoch
hardy sparrow
#

the lsp is a huge win

chilly arch
rigid epoch
swift inlet
rigid epoch
#

oh, this looks great!

chilly arch
rigid epoch
#

ooh, thanks!

arctic edge
#

Any Dockerized Django with database(MongoDB) app examples here?

sharp marsh
#

@hereHappy Friday community! And what best way to celebrate but to ship a new feature in Dagger Cloud. For those users that have their engine connected and sending telemetry to Dagger Cloud (https://docs.dagger.io/1241/dagger-cloud/), we've just released a feature that will now display the caching status for your actions. This will help you understand better where and why some actions in your CI / CD process could be taking more time than expected.

As always, if you have any feedback or suggestions feel free to share them with us here https://github.com/dagger/dagger/discussions/2783#discussioncomment-3262864 so we can improve dagger to make your work easier.

GitHub

If you used https://dagger.cloud with dagger let us know what worked well and what you wish was better. All & any feedback welcome! If you are curious to learn more about how Dagger Cloud m...

drowsy glacier
#

ๅคงๅฎถๅฅฝ

coarse jolt
stuck wyvern
#

Great work on the cue LSP!
Really nice to be able to jump to definitions easily.

chilly arch
#

@here I'm happy to announce that our team has revamped the Dagger docs experience, making it easier for new users to get started. Please take a look and let us know what you think!
Dagger Docs - https://docs.dagger.io/

You'll find updates like:

#

Thank you to @slender star @glad jolt @mint axle and @swift inlet for all their work on these updates! We look forward to bringing y'all even more new content soon!

verbal canopy
#

I've worked with Bake, Earthly, and Dagger, and this is miles ahead of any documentation I've read on BuildKit.

chilly arch
stuck wyvern
#

Was about to upstream an action for inject go into an arbitrary image (in the go package) but naming is hard.
I was calling it #Install, but as I'm working to add it I realize "oh there's already actions for test, build, <etc>"... go install is a thing already and a #Install action that is not go install is confusing.

sharp marsh
stuck wyvern
sharp marsh
fallen moat
#

Hi, are there any examples of multi-stage Dagger pipelines on Gitlab? I want to be able to trigger some jobs of the pipeline using the Gitlab UI

mystic mantle
willow rune
#

Hello, Dagger has portable version on Windows ? I cant install anything new on my corporate laptop but I would like to check this Dagger

verbal canopy
#

But you do need access to a host running Docker.

willow rune
#

but the Windows install says use choco or ... other ways to install

#

Docker is allowed to run our corp laptop

#

where can I download the binary exe for Windows ?

willow rune
#

many thanks

#

!

#

I also thought that running CI\CD locally can be keypoint because too many problems can occur with remote hosted CI\CD

#

and an developer not interested in why a software can not be build and released on the hosted CI\CD

#

too many problems ok guys I made a specific version building locally and take it I dont interested in why the corp CI\CD not enough flexible

#

@verbal canopy link is broken

sharp marsh
willow rune
#

@sharp marsh many thanks

still gull
safe storm
#

Hi, I am still confused on how to integrate dagger with Jenkins, in case for dagger to talk to on-prem docker registry with self-signed certificate. Here is the doc url: https://docs.dagger.io/1224/self-signed-certificates/. How to create some Jenkins stage task to run this command only once on Jenkins agent host? Need to figure out how to only run this command in some Jenkins stage shell task only once on each Jenkins agent host? ```docker run --net=host -d --restart always -v $PWD/my-cert.pem:/etc/ssl/certs/my-cert.pem --name dagger-buildkitd --privileged moby/buildkit:latest

The connection to a container registry or to a remote docker daemon might require the need to add self-signed CA certificate signed by unknown authority.

winter linden
#

In case anyone is at vmware explore tomorrow in SF: https://twitter.com/solomonstre/status/1564855297855741953

Tomorrow I will be presenting at #VMwareExplore DevOps Loop. See you at the pop up theater, 11am. There will be live demos of unfinished code lovingly prepared by the @dagger_io team. Rumour says the one and only @BettyJunod may even be attending ๐Ÿคž

Feels like old times!

winter linden
winter linden
wet fox
#

Running Dagger with self-signed certific...

cosmic maple
#

VMwareTanzu - Twitch

lilac thicket
#

Well done @winter linden ๐Ÿ™‚

chilly arch
#

@here The team has been working hard on some new capabilities for Dagger. @winter linden is at VMware Explore right now, and just did a demo to showcase the multi-language support that we intend to bring to Dagger.

You can check out the demo and interview here:https://www.twitch.tv/videos/1578035654

The project is currently in private beta, but you can sign up for access through the private beta form at https://dagger.io/cloak.

Twitch

vmwaretanzu went live on Twitch. Catch up on their Software and Game Development VOD now.

โ–ถ Play video
#

NOTE: he had some technical difficulties at the start, but the VMware events team fixed it at the 16:40 mark ๐Ÿ™‚

tender goblet
# stuck wyvern Great demo.

Indeed! Really excited to see how Dagger is evolving. Where Pulumi, my employer, is adding programmability to cloud infrastructure leveraging regular programming languages, Dagger is taking programmability to delivery flows. ๐Ÿ‘๐Ÿผ

supple hornet
#

Hey @chilly arch is the community call later today going to include the proper demo that was intended for VMware Explore? I was quite excited by the little bits we got to see ๐Ÿ˜„

chilly arch
#

@supple hornet we most likely won't do the full demo, but @winter linden will be there to dive into any parts that you'd like to see again and our engineering leads will be there as well to answer any questions!

tulip rune
#

is the new docs site using docasaurus?

glad jolt
stuck wyvern
#

Just used core.Source for the first time... that's a nice little thing to have.

winter linden
#

If anyone here signed up for early access to Project Cloak and didn't get in yet, please DM me or @slender star and we'll give you access. If you're active enough to have joined our discord, you get priority ๐Ÿ™‚

wet fox
#

I just realized that I lost the today's cloak zoom call ๐Ÿคฆโ€โ™‚๏ธ . Is there any chance I can see the recording of it (if there is any)?

winter linden
#

Yes we switched to zoom specifically so we could record ๐Ÿ™‚ Will share soon

wet fox
#

Thank you!

stuck wyvern
stuck wyvern
sharp marsh
modest nova
stuck wyvern
winter linden
gilded vortex
#

Thoughts on having a .cue file for frontend and backend repos? I'm working with a mono-repo and initialized the dagger project at the root. Squeezing in a ton of commands for both backend/frontend into a cue file seems to be getting a bit messy

winter linden
#

At the moment the actual contents of universe are bundled in the dagger binary

#

But the UI assumes that in the future it will be moved out and downloaded as needed

stuck wyvern
winter linden
#

Well it's "fetching" it from memory ๐Ÿ™‚

#

The plan is that it will eventually fetch it from a repo instead - or that it will hand off to native cue package management to do so, whichever comes first

gilded vortex
stuck wyvern
#

lol, I have so much indirection or something in this build I'm working on, it's taking forever for dagger to figure out what to do.

slender star
stuck wyvern
stuck wyvern
raven quest
#

Has anyone explored running macos builds? We have some CI steps that need to run on OS X, but it doesn't seem possible to do that with Dagger.

sharp marsh
#

Has anyone explored running macos builds

stuck wyvern
#

The vscode cue/dagger introspection has been really off the last couple of days, I'm guessing there was some update that broke something.
Sometimes I'll try to inspect some type and it just gives nothing at all (for dagger/core this seems to be 100% broken for me). Other times it takes me to the wrong type.

swift inlet
#

lsp broken

verbal canopy
#

It would be awesome to have this functionality with Dagger

sharp marsh
frozen basin
#

Anywhere yall are talking about cloak? Or is that only after EA invites go out? ๐Ÿ™‚

winter linden
#

@frozen basin there's a separate discord channel so as to not confuse the hell out of everyone ๐Ÿ™‚ Did you sign up for early access? We're sending another batch later today

winter linden
#

@slender star I'm guessing you're already on it? ๐Ÿ™‚

slender star
#

yep!

winter linden
#

If anyone reading this has signed up, and doesn't get access within 1-2 days, let us know

#

We're prioritizing people already active in discord or github

sullen thicket
#

Hey, I've been experimenting with Dagger recently. Wondering if there's any thoughts on how to structure a CI/CD pipeline using Dagger in GitLab - should I make a single Dagger action that does all the steps (e.g. test, lint, build, deploy), or multiple actions and therefore multiple GitLab steps? I can see pros and cons either way; a single action for all those things would probably require explicit chaining which Dagger doesn't natively support yet (aside from the workarounds), but multiple actions would require more GitLab CI to be written and so it feels like it loses some of the advantages of the decoupling/'run anywhere' philosophy. As far as I can tell, single action would also mean the whole pipeline is just represented as one step in GitLab CI which feels suboptimal.

swift barn
#

are there any strategies for working with local things? Like using a tool in a container to generate some output you want to use locally. Similar to something like

docker run -v $PWD:/work my-tool generate
#

I feel like this capability would be nice. Currently I am still using makefiles for this kind of stuff. But I wish I could drop the makefiles and centralize everything in a dagger plan.

slender star
#

are there any strategies for working

swift barn
#

Hi, is there a way to know what action was invoked by dagger do ?. I want to do this to do some conditionals based on the choosen action. The reason is that there is this issue that the pipeline fails if not all env variables are set as soon as one action touches the client env. So the idea is to declare the variables conditionally based on the chosen action.

swift inlet
#

knowing action invoked

mystic mantle
#

Dagger Project structure in GitLab

frosty oak
#

Hi, I am trying to with dagger to replace bash + makefile and have a small problem that need help. There are a few tasks that would want to see the action stdout output, ie:
output of terraform plan to decide if I should apply it or not, task that reports list of vulnerable packages ... I found out about action output https://docs.dagger.io/1228/handling-outputs#controlling-the-output but it is not suitable for terraform plan output, or multiline string in general. Log format doesn't help much as well.

I can work around this by writing output to a file, copy it back to client and ... use cat (bash script) to show it out but that sounds way too complicated and kinda defeat the purpose of using dagger in the first place.

So could u point me to any reference where I can see stdout of an action.

swift inlet
gritty star
chilly arch
#

@hereHi Dagger Community!

You may have heard the buzz around a mysterious โ€œProject Cloakโ€: an experimental project to add multi-language support to Dagger. The experiment started in a separate repository, but we are now migrating it into the main Dagger repository. โ€œCloakโ€ is the codename of our next major release of Dagger, and going forward we will be developing it in the open.

You can watch Solomonโ€™s demo to learn more: https://www.twitch.tv/videos/1578035654

The stable Cloak release is still several months away. You can continue using Dagger as usual, and we will offer backwards compatibility in the future.

Here are a few ways to get involved:

  • Check out Cloak in the Dagger Repo
  • Create issues with your feedback using the cloak label
  • Join the conversations on the #maintainers channel in Discord
  • Join the weekly Community calls on Thursdays at 10 am PDT. You will see event reminders on the event section on Discord. If youโ€™d like to get an invite directly to your email, please DM me.
  • Share your use case for a multi-language Dagger! We love to talk to our users, so please feel free to reach out to me, so we can schedule some time to talk!

**Please remember: **

Project Cloak is still under active development, and you will certainly encounter bugs, confusing behavior, and incomplete documentation. Please tell us everything!

Thank you again for being an active part of the Dagger Community, and we look forward to building this new release with you!

marble vapor
winter linden
#

Since we're developing multi-language support for Dagger, I'm curious: if you could choose any language to develop your pipelines with the Dagger engine, what would it be? (vote in the thread)

swift barn
#

would it be possible to redact strings (from error messages) that are wrongly passed to Secret fields? Because if the user did something wrong and tries to add a string from something like a client command stdout to a secret field, cue will throw an error and say that value "supersecret" doesnt match the type. And then it goes off into dagger cloud.

native hinge
#

cloak & dagger, har har

(j.k - look forward to it!)

winter linden
swift barn
#

string may come from a client command that wasnt configured correctly.

slender star
#

If everything is done correct secrets

boreal tide
#

is it possible to pass on all env variables from the client environment that are of certain wild cards say abc_* to dagger workflow actions? I don't want to add each and individual env

winter linden
alpine wyvern
#

Hey !
I'm the product owner for a small project in a large Data Science consultancy, and I often have to setup CI/CD for our clients. I was very eager to try out Dagger as an improvement over rewriting CI pipelines every times. However I have a few questions I could not find the answer to (I hope you don't mind!) :

  • How do I manage concurrency in CI with Dagger ? For example, I'm using Circle CI with separate jobs for linting, building the docs and testing the code. They all get executed in parallel over different containers with their own resource pool. How would that fare if I invite dagger in ? Could I still benefit from multiple resource pools ?
  • How do I cache stuff (like deps, venv, etc) ? Do I still have to use the CI provider's caching mechanism ? To be honest that's 1/3 of all I have in the workflow (alongside fetching code, secrets, and recording artefacts)
  • If I disregard the CI completely, would dagger be a better fit to replace Airflow and other schedulers ?
  • I was about to say that the cue lang was really putting me off, but I read that cloak could make it available in other languages; so, everything's fine ๐Ÿ™‚
chilly arch
#

@here Hi everyone! The Dagger team is currently having a great time at our team retreat in SF. As some of you may know, we don't have the community call this week since we are at the retreat. We look forward to seeing all of you next week! Use the link below to easily add next week's call to your calendar: https://discord.gg/aUJws773?event=1022258709260410982

If you would like to add a demo, topic, or question to the agenda, please add it here: https://docs.google.com/document/d/1-6RSWHwFoZr588kftPLVvT1RCHUrOrnmURldBRrP1Ak/edit?usp=sharing

young stag
#

Hi. Iโ€™ve a quite generic question; does dagger offers a (RESTful) API or smth like that? Iโ€˜d love to make an UI so jobs are visualized :)

carmine sandal
#

anybody has any good advice/resources/tutorial on how to setup Dagger that requires interaction with other Docker containers for e.g. https://localstack.cloud

LocalStack

Develop and test your cloud apps offline.

wraith niche
#

web api

#

docker containers

chilly arch
winter linden
#

Data science use case

swift barn
#

Hello, Dagger newbie.
Although I understand that any OS that supports DevKit can be used to run a dagger pipeline, what is unclear to me is how to build binaries for macOS as a target (with macOS as a build host, I don't even need cross-compilation). Do I need to use QEMU or is there a more direct, more performant way? A quick search of the documentation didn't help, maybe I missed something? Thanks ๐Ÿ™‚

pseudo stream
#

Hello Dagger newbie

tall gulch
#

Hi, I'm looking for a workaround for explicit dependencies with client commands https://github.com/dagger/dagger/issues/940, or other approach to achieve dependencies between actions which exec into containers. The containers are managed outside of dagger.

oak quest
#

Tonight, Europa will be visible with binoculars!

https://twitter.com/astro_jaz/status/1574186492104445952

Tomorrow, an incredibly rare, once-in-a-lifetime astronomical event is happening! Jupiter will be its closest to Earth since 1963! Along with opposition, itโ€™ll be SO bright, youโ€™ll be able to see its bands and some moons just with binoculars!
This wonโ€™t happen again until 2129!

Likes

152197

Retweets

25594

winter linden
#

Good to see you again here @oak quest ๐Ÿ™‚

oak quest
#

and you @winter linden ! I have a real world need for Dagger atm

#

did I inadvertently leave #dev or was that channel removed?

winter linden
oak quest
#

ah

winter linden
#

It was turning into a catch-all

chilly arch
oak quest
rain oriole
oak quest
wraith niche
chilly arch
#

@here Our first official community call with the entire Dagger Community is on Thursday. If you would like to add a question for the group, a topic, or even a demo, please feel free to add it here:https://docs.google.com/document/d/1-6RSWHwFoZr588kftPLVvT1RCHUrOrnmURldBRrP1Ak/edit#heading=h.amkecn1w3n3t

These calls are the evolution of the Cloak Community Calls that some of you have already been attending. You can easily add this week's call to your calendar by using the link here: https://discord.gg/6R866YsK?event=1022258709260410982
(if you would like to have the reoccurring event added to your calendar through a google invite, please DM me your email, so I can add you)

rain oriole
winter linden
#

Man... here in San Francisco the night was too cloudy. I didn't see anything ๐Ÿ˜ฆ

oak quest
slender star
#

We could see 4 moons in Portland, OR last night with big binoculars

winter linden
#

Hoping youโ€™re safe and have a full pantry @stuck wyvern and everyone else in the path of Ian..

stuck wyvern
winter linden
#

oops, sorry ๐Ÿ˜… parasitic memories

oak quest
#

What's the current state of Dagger CUE support? I'm needing to deploy AWS resources which may lead to contributions to universe. Is that a worthwhile endeavor at this point?

#

well well well what do we have here? ๐Ÿ™‚

#

I see a few different extensions for Cue, some more recently updated that others. Anyone have a particular favorite?

stuck wyvern
#

I hear dagger is pretty good.

slender star
chilly arch
#

@here the community call is going on right now, so feel free to join! @pseudo stream is doing a demo on multiplatform support right now.

Join Zoom Meeting
https://dagger-io.zoom.us/j/89360226840?pwd=aEZqU2Zsai9ScXhCcUwyZlp4RUpvQT09

Meeting ID: 893 6022 6840
Passcode: 652511

timber sphinx
chilly arch
#

I will always share the recordings after the calls on this Discord channel, but you can find the previous ones in our community call notes. -https://docs.google.com/document/d/1-6RSWHwFoZr588kftPLVvT1RCHUrOrnmURldBRrP1Ak/edit?usp=sharing

swift barn
#

Hi, if you have a multi stage docker file, and build one stage first and then later the full image, does the caching work as in normal docker, meaning it doesnt need to do the things from the first stage anymore?

winter linden
sharp marsh
swift barn
#

ok thanks.

#

its strange because I feel like dependecies are pulled twice.

sharp marsh
swift barn
#

sure, let me login to cloud and share a run

#

its also suspicous that vet and test take 41 seconds. They take less than a second locally.

sharp marsh
sharp marsh
sharp marsh
#

looking into the Dockerfile thing now

chilly arch
stuck wyvern
#

Phew, gonna have to get a bot to clear my inbox from the dagger community call invites.

chilly arch
#

Sorry, was updating the invite to change the wording from cloak preview to community calls. I clicked "don't send" for sending updates to the invite list, but go to know that button doesn't actually do as it says ๐Ÿ˜‚

rigid epoch
#

Does Cloak support storing non-image outputs as OCI artifacts?

winter linden
#

Sure

#

except for custom content type

#

so registry will gladly store it but think itโ€™s a regular container (probably better that way for compat)

rigid epoch
#

And I was curious how Dagger handled that / will handle it in the future

pseudo stream
# rigid epoch I think that's what I was thinking of, but not sure ๐Ÿ˜… I've only just begun read...

Haha yeah it sounds like that's what you're describing (helm charts are a common example I think, but now also SBOMs and some other exotic things).

We don't have built-in support for any of that (pretty much just because buildkit doesn't have built-in support for exporting generic oci artifacts). But I do suspect it would be straightforward to implement this in a user extension; you could just import an oci registry library with artifacts support (in whatever language) and then append the artifacts to whatever you want.

That's very theoretical because I have not tried it before though, so take with salt. If you have some specific examples of artifacts your team might want to utilize that would be helpful to get a better idea

rigid epoch
#

I was thinking of binaries, frontend assets, that sort of thing. Really anything that isn't an image, but not any specific standardized type

winter linden
#

Honestly you can do almost all of that without messing with the content type

#

So my guess is that if you control the tooling on both sides, you can already fo this with dagger.

If you donโ€™t control the tooling and need to use tools that rely on recent extensions of the OCI format (like mew content types) then :

  1. like @pseudo stream said itโ€™s not supported natively but probably could be soon
  2. you can just wrap the particular tool you want to use in a dagger pipeline, and let that tool deal with the OCI extension stuff

TLDR:

  • You can probably do it now with some limitations
  • Eventually there will be no limitations
#

Actually reading that โ€œartifactsโ€ repoโ€ฆ Iโ€™m really not conviced you need that spec at all to achieve your goals

#

It becomes useful (I think) when multiple vendors need to agree on content types for interop, to reuse each otherโ€™s artifacts and metadata

#

I say shove your artifact in a dagger directory; add a json file with your custom metadata if needed; push it as a 100% vanilla container image with your artifact as rootfs; done.

#

if in the future your tool doing this gets millions of downloads, then OCI will need to adapt the spec to be compatible with your thing. Kind of the true purpose of OCI in the first place ๐Ÿ˜

slender star
#

Earlier today we were working with a user that was pushing Helm charts from Dagger using helm cli inside a container like this:

helm push helm-test-chart-0.1.0.tgz oci://aws_account_id.dkr.ecr.region.amazonaws.com/

https://docs.aws.amazon.com/AmazonECR/latest/userguide/push-oci-artifact.html

chilly arch
#

@here time to add your topics, demos, and/or questions to the Dagger Community call agenda ๐Ÿ™‚ Feel free to add them to the doc below: https://docs.google.com/document/d/1-6RSWHwFoZr588kftPLVvT1RCHUrOrnmURldBRrP1Ak/edit#heading=h.9t6gqibgvt7n

See you at the community call on Thursday at 10 am PDT! You can add it to your calendar using this link: https://discord.gg/jEbTGnbt?event=1025170650752630854

timber sphinx
#

I wanted to restart a run through of dagger for a project. Should I do it from branch with cloak or normal install is fine? I couldnโ€™t find the Hugo demo someone had done a while ago so post a link if itโ€™s still around and relevant. Cheers

winter linden
timber sphinx
winter linden
mystic mantle
chilly arch
timber sphinx
#

Best place to post ideas for consideration? Github discussions?

winter linden
#

Github discussion is excellent. You can also start here in #general or in #maintainers if it's specific to the future cloak release. Whatever you're comfortable with

#

Github discussion thread is more durable and easier to find for sure

swift barn
#

Hi, I am still looking for a solution to integrate with docker compose. This is a real showstopper for my team since they want to run integration tests utilizing their development compose file. I cant promote dagger without having a solution for that :/

sharp marsh
swift barn
#

Although we use buildkit directly on our agents, I am not sure how this would play out in that case.

sharp marsh
slender star
chilly arch
chilly arch
#

During the call, there were a few key issues/prs/discussion posts that were mentioned and put in the zoom chats, you can find them noted here:

GitHub

Overview In the upcoming cloak release (0.3) the primary use of Dagger will be to embed it in a script. In the case of shell scripts (bash, zsh, powershell etc) the simplest approach is to invoke t...

GitHub

Signed-off-by: Erik Sipsma erik@sipsma.dev
See updated go extension docs and updated examples/alpine+examples/netlify/go for usage.
TS+Python currently still use schema.graphql, only Go is updated ...

GitHub

This PR adds support for services, specifically:

Creating services (asynchronous containers)
Service control (listing, retrieving, stopping, ...)
tty streaming over WebSocket with CLI support (clo...

GitHub

We should have an SDK that supports at least authoring workflows (and possibly extensions too) w/ bash scripts. It would be great if it turned out that this just meant using the same cloak CLI that...

pseudo stream
mystic mantle
#

Has anyone here some experience with scaleway elastic metal?

sharp marsh
sharp marsh
pseudo stream
#

The network namespace that buildkit runs its containers in is a different issue

pseudo stream
sharp marsh
swift barn
#

Would be nice to have something like vscode devcontainer where you can point it to a compose file and tell it which service of the compose thing is the target. And then it starts the whole stack and uses the target, in this case some builkit image. That way you could have dagger run and use tests commands, in your actions, against sidecars in the network(s) configured by compose.

faint sail
#

Is there a design document for cloak (direction, reasons etc)?

winter linden
#

The short version of โ€œwhyโ€ is that our number one user request, by far, is โ€œsupport more languagesโ€

faint sail
#

Config languages or target languages?

#

I guess that means even tighter integration

winter linden
tall gulch
# winter linden The short version of โ€œwhyโ€ is that our number one user request, by far, is โ€œsupp...

https://learn.acloud.guru/series/serverlessconf-nyc-2019/view/yaml-better at 14m22s: `But I wanna always code in my favorite language!" : "So grow up! Here is the thing, your comfort zone is not the point!"

faint sail
#

I'll check it out. Looking at the examples and core extentions for cloak (even after code first) being so language agnostic makes it feel not very specific language friendly.

The go code feels more graphql than go. Then there is the idea of compiled code masquerading as a scripting language.

All of this made me wonder more about the underlying decisions and hoping there was a design doc that stepping through the idea of graphql, etc.

#

So the idea of writing in any language makes sense. The implementation and real world use case seem more ambiguous.

pseudo stream
faint sail
#

Nice.

winter linden
timber sphinx
# tall gulch https://learn.acloud.guru/series/serverlessconf-nyc-2019/view/yaml-better at 14m...

I listened to the talk, but Iโ€™m not sure how that applies to dagger. This talk was specific to where in the abstraction for infrastructure should tools sit. While dagger seems to have some declarative aspects it seems more imperative sets of packaged instructions and less focused on desired state. Maybe create a thread of that doesnโ€™t make sense and want to talk more about it? Itโ€™s an interesting topic. Iโ€™ve debated this in using Pulumi and other tools before and arrived at my happy compromises.

tall gulch
winter linden
#

@tall gulch whatโ€™s your preferred environment for developing and running CI/CD pipelines? Have you used Dagger with CUE and if so, do you have any requests for improvements?

tall gulch
# winter linden <@1023669044676669470> whatโ€™s your preferred environment for developing and runn...

I think my favorite CI/CD environments were jenkinsfile with groovy and buildbot with python. Both allowed me to organize the pipelines into functions without yaml boilerplate, but the infrastructure was not reliable (jenkins plugins were fragile to updates). I tried dagger with cue, but found cue initially unreadable. I'll invest time in cue only if it solves my problem. My goal is to reduce the time spent on debugging the pipelines. In order to do so I imagine being able to selectively restart dagger actions using the original or modified (for debugging) pipeline code. I'm hoping that most, if not all traditional yaml pipeline constructs, even the more advanced ones (like https://github.com/dagger/dagger/issues/3149) can be represented in dagger somehow, and cloud identities propagated to dagger so I don't need to carry secrets around when running on a cloud (with an approach like https://github.com/kubernetes-client/python/issues/1005).

timber sphinx
#

So the last time I touched dagger was early last year at least. I asked last week about what version too use.
Hugo examples seemed to be in process of being updated, so instead...

Here's a recent enhancement I did for some of my $work public open source repos. (granted I only started using github actions with composite and such in the last few months, so maybe better way to do some of that).

release-composite: https://github.com/DelineaXPM/dsv-github-action/blob/main/.github/workflows/release-composite.yml

Now I'd like to replicate some steps, and I'm fine with whatever is stable and not subject to immediate breaking changes. If that's dagger classic with cue I'm fine trying that out. Most of the tasks are Mage driven. If that's better in cloak and the sdk is "reasonably stable" in that I could use it for a few months without worrying about entire sets of functionality being gone ,then I'll try cloak.

I also am going to look at putting trunk cli in this process as a container.

What route/branch etc should I give a shot and if there's no init to setup a starter plan file where do I grab the correct one?

No rush just want to give it a shot again!

GitHub

A GitHub action integrating with Delinea DevOps Secrets Vault. - dsv-github-action/release-composite.yml at main ยท DelineaXPM/dsv-github-action

#

Seperate idea/thought:

Might consider looking at trunk.io for perhaps a nice way to feature a linting toolchain/partnering or mentioning. Their community /slack group is very responsive and I've been rolling out trunk for formatting, linting, and triggering tests before push, removing pre-commit entirely. It's such a good experience compared to self-built toolchains of this stuff. Just thought trunk + dagger might be an interesting mix for the "chore" style lint/formatting/precommit style hooks.

chilly arch
#

@hereHope everyone is having a great week! Just a reminder that our community call is tomorrow at 10 am PDT.
https://discord.gg/VasygkaV?event=1027696167192117259

You can add any topics, questions, demos, etc. to our agenda here -
https://docs.google.com/document/d/1-6RSWHwFoZr588kftPLVvT1RCHUrOrnmURldBRrP1Ak/edit#

strange jungle
#

Hello everyone. I'm working at Cycloid, and we have built a product, a devops platform, that is currently using Concourse (choice made in 2017) for providing all the automation.

I'm currently happy to see that @elfin frigate joined Dagger project, but a bit sad also as that means Concourse lost his captain/father.
So I'm currently working on preparing the future, and as few customer told us they would like to use their CI/CD engine and not switch on Concourse, I think Dagger totally make sense for us to have an easy integration by having this engine abstraction.

Few questions come to my mind:

  • what is the current plan with Dagger cloud (business model I mean)? I wouldn't like to start something on top of dagger with an UI etc, but finally compete with you and you'll close API/Engine etc ...
  • do you think it would be possible to have a way to stream logs/plan of actions etc ? Maybe with an agent/wrapper ๐Ÿคท ? Is it something you plan to do with Dagger cloud ?
  • @elfin frigate I saw you did an image vito/dagger-concourse, do you have a PoC working between concourse and dagger ? (that would be a first step to integrate dagger in our current ecosystem

Thanks ๐Ÿ™‡โ€โ™‚๏ธ

winter linden
elfin frigate
# strange jungle Hello everyone. I'm working at Cycloid, and we have built a product, a devops pl...

hiya! I don't remember making a vito/dagger-concourse and can't find it now, but I am good at hiding things from myself. ๐Ÿ˜…

I have thought about Dagger as a potential landing spot for Concourse users, but don't have any work in progress. Concoure resources had a really simple container JSON stdio interface that can definitely run on Dagger, the only problem being they took arbitrary JSON payloads on stdin which a GraphQL can't represent in a nice way (there's no "arbitrary params" type) so using them directly with the Dagger SDK wouldn't be very ergonomic even if an extension were to be built for it. Concourse tasks would be pretty easy to run with Dagger though, and I also have an in-memory streaming implementation of Concourse's pipeline passed: constraints stashed away somewhere. Building on those primitives, it seems possible to implement a Concourse pipeline interpreter that runs on Dagger without a database or web UI. It'd be a decent chunk of work and I've got other distractions at the moment, but I'd like to see it happen someday and would be more than happy to help!

slender star
chilly arch
rocky sage
#

Hello to all here ! I am glad to join Dagger community salute

rocky sage
winter linden
# winter linden Hi Seraf! Thanks for saying hi. Thatโ€™s a very interesting use case that I think ...

A few thoughts as promised @strange jungle ...

  • Our business model is to sell subscriptions to Dagger Cloud - a collection of optional cloud services that improve the experience of using Dagger in a way that the open-source engine cannot.
  • Our roadmap for Dagger Cloud is simple: identify the most painful obstacles encountered by the community when using Dagger, and look for the best solution. If it's an open-source engine feature, ship it. If it's one or more third-party products, integrate with them. If it's a cloud service run by Dagger: add it to Dagger Cloud. So it's completely driven by user pain, and identifying the best form factor.
  • Yes, we plan on offering a way to stream telemetry from your Dagger engines to Dagger Cloud. This is a pre-requisite for several features that we already know we need to ship. In fact we already built this for Dagger 0.2: you can connect to Dagger Cloud and share a link to each run, for troubleshooting and support. We haven't ported that feature to cloak yet, but we will.
  • We also want to support streaming telemetry from the engine to locations other than Dagger Cloud. It would be difficult for us to prevent it anyway, since the engine implementation and API are open source. Easier for us to embrace it: more integrations means a larger ecosystem, and we all win.
  • There's nothing preventing you from forking the Dagger Engine and removing the link to Dagger Cloud entirely - but our goal is to make it more interesting for you not to do that. We rely on strict enforcement of our trademark (you can't use the TM on a modified fork) but not on restrictive licensing. The engine code and API will remain open.
  • We expect many commercial products to integrate with Dagger Engine in ways that overlap with Dagger Cloud. That's just how the market works. We think that's compatible with a win-win relationship.
  • The only scenario that would not be a win-win relationship would be if you made the entire strategy of your business to be "the enterprise Dagger company". This is because Dagger is not and will never be a vendor-neutral platform, like Kubernetes or Linux. We will never donate it to CNCF. It is very open, and very friendly to integrations and partnerships - but it is still owned by a company called Dagger. You need to be OK with that or you will be disappointed later.
  • We will never close our API or open-source engine implementation - that would cause us to lose the trust of our community and ecosystem. FWIW we never did that at Docker either. We had non-open products, but they were all launched as such from day one. No bait and switch ever.

Hope this helps.

strange jungle
#

About Dagger Cloud

timber sphinx
#

Off topic - your developer environment and setup

chilly arch
#

@here Check out the community call recording from yesterday - The call includes a Go SDK demo and playground demo:
https://dagger-io.zoom.us/rec/share/guo7q5DobXhyXdKaBJc3RY7p55fIGV_HDWTpydlJy7v6H0dDXBPBWt9HiWD19tk.R15faI7hJGBs_CHS?startTime=1665680168000
Passcode: K?P#5.sL

blazing sluice
chilly arch
ruby harness
#

Hey Dagger Community,

I am Ganesh and I work as a full-time community person at Aviyel. I just discovered Dagger and thought I'd come around and be a part of the discussions. Meanwhile, if there's anything I could help with on the non-code side (I do have some ideas in mind) to spread the word, I'd be happy to volunteer.
Let me know your thoughts!

winter linden
#

By the way I didn't know about Aviyel, I love the website. Very cute characters.

hollow terrace
#

Hi! Sorry I have been away for a while so missed the new development, is CUE going to be depreciated in the future and replaced with the new Go /Py/TS sdk?

winter linden
#

In other words, a CUE SDK will be available for the new engine, with the primary goal being compatibility with existing CUE configurations

hollow terrace
#

Thanks for clarifying!

ruby harness
# winter linden By the way I didn't know about Aviyel, I love the website. Very cute characters.

Hey @winter linden thank you for your words
Happy to share the ideas with you

I have some ideas:

  1. if you don't already have one, a contributor guide for anybody getting introduced to Dagger for the first time. This is the high-level idea: https://aviyel.com/post/3369. Here's what it would look like finally: https://bit.ly/contributor-roadmaps

  2. An informal AMA session with our open source community https://www.youtube.com/watch?v=HQ9jYOFfCg0
    Let me know your thoughts on these ideas and would be great if you're available for a short call to discuss more.

Aviyel

To get the community introduced to an open source project, we built Contributor Roadmaps. These roadmaps provide a step by step journey starting from understanding the project vision, providing reso

Aviyel

Aviyel is a community platform for open source projects to monetise and be sustainable. Incentivise contributors, improve discovery and adoption of open source.

Peer shares his journey with COSS and building a successful product like Cal.com as this helps and motivates Maintainers, Startups, and Open source enthusiasts.

About Aviyel

The world of open source is vast and multidimensional. It is a space for the project maintainers, contributors, tech writers and even includes the businesses, developers, ...

โ–ถ Play video
somber finch
#

Hey guys, I just discovered Dagger and have a question around universe.dagger.io. Is there some place where I can see all the available Go modules?

somber finch
swift inlet
#

dagger do ci

ruby harness
#

Aviyel | Create a Contributor Roadmap fo...

timber sphinx
wary cave
#

Are contributions to v0.2 still accepted? Seems a lot of things are changing in v0.3 in main

winter linden
chilly arch
#

@here It's that time of the week again ๐Ÿ™‚ Add your topics, questions, and/or demos to the Community Call agenda.

https://docs.google.com/document/d/1-6RSWHwFoZr588kftPLVvT1RCHUrOrnmURldBRrP1Ak/edit#heading=h.gp78qpx3dfxe

See you at the Community Call tomorrow at 10 am PDT! - https://discord.gg/3myZmR4w?event=1030545484428869672

winter linden
#

If anyone here is interested in developing CI/CD pipelines in Go: consider joining the community call in 5mn ๐Ÿ™‚

winter linden
chilly arch
#

You can find the links to try out the demos in the community call notes here - https://docs.google.com/document/d/1-6RSWHwFoZr588kftPLVvT1RCHUrOrnmURldBRrP1Ak/edit#

pulsar sigil
#

hi, I am new here and have been looking into Dagger for a couple weeks. I was wrapping my brain around cue but now I see that 0.3 seems to be replacing this with more language specific APIs. I know that cue is supposed to be maintained via a compatibility layer, but is this still going to be considered a first class citizen moving forward or is there a desire to move away from cue and towards the Go SDK?

#

The other question I have is in terms of package management is the package management based on Git or will it be OCI images in the future? The reason I ask is I have some desire to use Dagger in an environment that may not have internet access and so the ability to proxy extensions would be very beneficial to me.

#

one of the biggest drawbacks I see to this solution is losing things like stage visualization when creating a pipeline in a tool such as GitLab CI or Jenkins. Is this something that the team is thinking about for the future? Perhaps through some sort of code generation to produce a Jenkins/GitLab CI file dynamically (not sure if something like this would be possible).

Anyway happy to be here, and I look forward to discussing with you all.

winter linden
winter linden
# pulsar sigil The other question I have is in terms of package management is the package manag...

It depends what you mean by "package management". Each SDK lets you use your language's native package manager (CUE, Go etc) just like any other software development project.

At the engine layer, we are developing an "extensions" feature that will be cross-language. There is still time to finalize the design. If you could share your requirements for using the Dagger Engine in an environment without internet access, perhaps in a github issue, that would be very helpful. One way or the other, we want to make sure that is supported.

winter linden
# pulsar sigil one of the biggest drawbacks I see to this solution is losing things like stage ...

You are correct ๐Ÿ™‚ We plan on doing two things:

  1. Help you generate Jenkins / Gitlab / Github workflows from your Dagger project. Note that you can do this manually in the meantime - the generation is just a convenience.

  2. Optionally hook up telemetry directly into the Dagger Engine, and give you a visualization service that works across all your CI runners, as well as development machines. Ultimately you will get more useful information from Dagger's telemetry, since it knows more about the logic of your pipelines.

Obviously we have neither of those features at the moment ๐Ÿ™‚

pulsar sigil
#

thank you for the responses. How do you handle complexity when you are building extensions and pipelines in full blown language specific SDKs? I guess one thing that originally drew me to dagger was it seemed like a relatively lightweight CLI binary that I could integrate with my CI servers and have a common code base. Now it seems like we may need to add the Go SDK and other SDKs to make the pipelines work. Are you all at all worried about complexity bloat from that and how will that be managed?

#

I love the idea of the code generation, I think that will be helpful. I have some teams using Jenkins and others using GitLab so having the ability to have templates in a common code base is one of the things I am interested in Dagger for as well as being able to run locally

#

the reason I am concerned about things like the Go SDK is in general I have always thought my containers running in my CI should be as small as possible with minimal dependencies

winter linden
#

Of course if the preferred language is a shell script rather than Go, then you should be able to write your pipeline logic in a shell script ๐Ÿ™‚

#

But it should be one simple shell script, that includes all the logic. Not one of 12 scripts and yaml files to be orchestrated in an arcane custom way

pulsar sigil
#

I think I can agree with that. I was a bit nervous about the complexities of cuelang for example. Yaml is not much better and a lot of teams struggle with defining pipelines in general. Jenkins gave people a lot of issues in particular

#

I mostly want as much of the complexity hidden from my dev teams in favor of shared, reusable templates

#

so that everything is on rails for them because I do not want them thinking about the intricate details on tool integrations

winter linden
#

Right. In that scenario the choice of SDK might be guided by the language preference of the "platform team" building and maintaining the rails for everyone else. Which again, may be Bash.

pulsar sigil
#

sure that is reasonable

#

I like the idea of being able to use an SDK for extensions that makes sense. IE python if I need to integrate with a python specific library, and golang for other things and wiring it all together

winter linden
#

Ultimately, with API extensions, these "rails" can be delivered as an API. All developers get delivered an API describing all the build, test, deploy pipelines available to them in a domain-specific way. Each developer can invoke these pipelines in whatever way is most convenient to them: command-line, shell script, NodeJS script, Python etc. All of it funnels through calls to your API (powered by Dagger + your extensions)

pulsar sigil
#

very cool. so I guess the thing I would like there is the ability to "bake" the extensions to an OCI image that was fully self contained so that using the extension was just pulling that image. It would contain the runtime needed to run that particular extension

#

that to me would be a powerful thing

#

I appreciate the responses here, it really helps me understand the future of Dagger

#

one area I see is turning source into a container. There are a number of solutions for this such as S2I, Jib, cloud native buildpacks, and the tanzu build service. It seems like dagger could be used to develop a source to container solution possibly. not sure if that makes sense for the project, but it is an area where some of the current solutions are not really fully adequate

winter linden
#

Yeah that is a major strength of Dagger since it is built directly on top of buildkit.

#

I'm confident you could reimplement any of those tools on top of Dagger and remove 90% of the code

pulsar sigil
#

yeah definitely. And still be able to run the unit tests ๐Ÿ˜„

#

cloud native buildpacks have a major drawback in that you need a parallel setup to run your unit tests which to me made them not viable

winter linden
#

Effectively we are making source-to-container a commodity

#

Right, it's a continuum between building a container and doing other things with it (like testing, generating a deployment configuration for kubernetes, ecs etc)

pulsar sigil
#

yeah

#

one of the first projects I have in mind to prototype the use of Dagger is to build a set of pipelines for handling secure software supply chains

#

I want to be able to build some tooling to help me ingress open source software

#

IE security scans, license compliance, etc

#

a lot of the tooling there is stuff I can template fairly easily and wire together.

winter linden
#

Yeah that seems like an excellent fit

#

What would be your language of choice for this?

pulsar sigil
#

probably python mostly but golang wouldnt be a bad second option

#

a lot of the APIs have python bindings

sharp marsh
winter linden
#

@pulsar sigil Python SDK is pretty far along ๐Ÿ™‚ /cc @rain oriole @wraith niche who can give you a sneak preview ๐Ÿ™‚

pulsar sigil
#

sounds great!

#

awesome yeah a python SDK will be a great feature

#

I think on the commercial side you would have Blackduck which is popular but expensive. Having some libraries for things like Trivy, DefectDojo, LicenseFinder, and maybe like the microsoft SBOM tool would be a good starting point I think

#

maybe some extensions for things like fossology as well

rain oriole
#

Yeah, early next week Iโ€™ll release codegen for Python. Then Iโ€™ll just iterate on more testing, docs and better demos.

pulsar sigil
#

awesome!

rain oriole
#

By the way @pulsar sigil, do you have a max Python version requirement?

pulsar sigil
#

probably targeting python 3.6 if possible would simplify things. I got some servers that run RHEL8

#

not sure if that is possible or not

#

if not then I will get whatever version is needed

#

3.6 is pretty old so I would bet it needs a newer version

rain oriole
#

Yeah, thatโ€™s pretty old ๐Ÿ™‚

pulsar sigil
#

hey at least it is not 2.7 XD

#

I had a team using CVS until last year soo

#

๐Ÿ˜›

wispy wave
#

Hello folk,
I have a writing problem with the client. But I think it's related to my environment.
I use a devcontainer for my projects, which creates a mount between my host and my machine in /workspace/my-project.
When I use dagger from my host, it works perfectly. But when I try from my dev container, I have an error:

[โœ—] client.filesystem."./public".write 0.2s
2:36PM FATAL failed to execute plan: task failed: client.filesystem."./public".write: error from receiver: error setting metadata for /workspaces/my-project/public/.tmp.087960590: lchown /workspaces/my-project/public/.tmp.087960590: permission denied
I think it's a problem with docker in docker when I try to write in a mounted volume.
Have you ever had this problem? If so, do you know how I can get around it?

slender star
slender star
slender star
#

Hi Dagger Community!! @warm temple and I are at Kubecon NA in Detroit this week. If you're around right now, we're in a 2nd floor lounge across from the Grand River Ballroom on the way to the Day 0 sessions. Come say hi! ๐Ÿ‘‹

winter linden
narrow bane
#

Can't believe I had to choose between my professional interests (Node) and my personal interests (Rust) ๐Ÿ˜ข

runic heron
#

I'd been keen on seeing what could be done for a Java API ( have actually been looking at GraphQL java libs recently - or Kotlin - tho pure Java would be nice, either via JBang or the fact you can just java Foo.java and run that as a "script"

swift inlet
runic heron
#

(JBang brings support for dependency management - which the simple java one doesn't)

runic heron
winter linden
#

@runic heron well now you've got to vote for Java in that poll ๐Ÿ™‚

runic heron
#

@winter linden already did ๐Ÿ™‚

#

For these non-go APIs, how is the "engine" started? Run it as a daemon somewhere, or System.exec("go-dagger-go") type process invocation? Liking the direction cloak/dagger is doing here -

winter linden
#

There's a bit more nuance than that if you zoom in... Starting with the fact that, currently the "engine" is made of two parts: an api router on the client machine, and a runner on a worker machine. So really your SDK execs the former, and (for now) auto-runs the latter in a container. There is some ongoing work to move the entire engine server-side, leaving just a "smart proxy" to system-exec on the client machine. But the result is the same for the SDK

runic heron
#

Right - I was gonna say, rewriting the entire engine seems crazy, but that router sounds like a proxy/bridge

winter linden
runic heron
#

We all do..... We all do ๐Ÿ™‚

#

So my doc keeps telling me.

swift barn
#

Hello, I just skimmed through the docs and cannot seem to find a deployment diagram. This comment above helped a bit:

There's a bit more nuance than that if you zoom in... Starting with the fact that, currently the "engine" is made of two parts: an api router on the client machine, and a runner on a worker machine.
But I'm wondering - how is the runner executing tasks? Is there an extension API similar to Jeknins where one can run jobs localy, on VMs, launch VMs on demand, use a cloud provider etc. ?

solar bison
slender star
# swift barn Hello, I just skimmed through the docs and cannot seem to find a deployment diag...

@swift barn @solar bison Good point! Today you don't need to do anything special to deploy the Dagger Engine. When you use one of the Dagger SDKS, a Dagger Engine will get provisioned on the fly for you. Like @solar bison said, there is Buildkit magic inside that allows all of your build steps to execute in containers ๐Ÿ™‚ In the near future, there will be other ways to deploy the Dagger Engine. A deployment diagram is a great idea.

Which SDK would you use? Or if your preferred language isn't there yet, which one would you vote for? https://blocklayer.typeform.com/to/a6m5gKSS

swift barn
pulsar sigil
#

I put my vote for Python. Rust is cool and so is Java but I need Python sooner so I can do the real work I got ๐Ÿคฃ

#

Python is used heavily by my shop

wraith niche
wraith niche
hoary spoke
winter linden
rain oriole
#

I put my vote for Python

chilly arch
#

@here** Today we are proud to introduce the Dagger Go SDK: a new way to develop your CI/CD pipelines as code and run them anywhere. Check out the links below to get started or learn more: **

Donโ€™t forget to join our community call this week at Thursday at 10 am PDT for live demos, https://discord.gg/KprBdzKn?event=1034224930943930490

winter linden
blazing sluice
#

Congrats! It's a nice API, and pretty easy to use. The Cubzh team is already setting-up a CI/CD with Dagger Go SDK on https://github.com/cubzh/cubzh ! โœจ

runic heron
#

Does the GoSDK have a nice pretty-printed progress output like the old dagger-cue - or that polish yet to come? Have a super simple lame little test project building with the GoSDK now - sure, it's little more than just the tutorial - but working is a starting point. Time to try something more complex

winter linden
#

oh sorry you mean the really pretty one ๐Ÿ˜… I donโ€™t think we have that polish yet

#

but can add it easily. Would you mind opening an issue?

runic heron
#

Will raise it in a bit - almost time for dinner and I need an escape away from that computer for a bit - Nice to see the underlying docker output when debugging tho ๐Ÿ™‚

winter linden
#

To clarify, there is an option to get raw log output. But it's not pretty-printed.

runic heron
runic heron
#

Hrm - have I done something stupidly simple wrong - clean project:

go run main.go
# github.com/moby/buildkit/session/filesync
../../../golang/pkg/mod/github.com/moby/buildkit@v0.10.5/session/filesync/filesync.go:112:20: cannot use dir.Map (variable of type func(string, *types.Stat) bool) as type fsutil.MapFunc in struct literal
#

have I missed some override? I did the mod replace

#

mmm, I think I'd broken something in my go.mod

swift inlet
runic heron
#

Yup! Now looking at how to add my github auth for private repo cloning. Altho its 10pm and I'm getting tired.

swift inlet
runic heron
#

It's that "Plaintext" link that's 404ing - navigating around manually seems to work, just found the WithMountedCache which solves a bug bear I've had with a lot of docker/buildkit style pipelines - caching my build cache ๐Ÿ™‚

#

altho - that MountedCache doesn't seem to be a docker volume (maybe that I was a bad assumption there). lets see if this still does want I'm expecting

sharp oracle
#

Dumb q about something I possibly misunderstood โ€” does Cloak mean CUE is going away, or it just means it will be kept supported alongside the new SDKs?

runic heron
#

@sharp oracle My understanding is cue remains, but isn't going forward in the future. Cue was.... interesting - but also felt kinda awkward.

swift inlet
swift inlet
runic heron
#

with all this Cloak and Dagger malarkey - are those who love Dagger Paladins, or Mercenaries?

fossil pine
#

Most examples seem to check out repositories, not use the local copy to run builds/tests. Is that to make examples easier/more self-contained?

rain oriole
# runic heron <@106011395186790400> My understanding is cue remains, but isn't going forward i...

@sharp oracle The future of the CUE SDK will depend on demand. The one that was launched this week is just a rebranding of Dagger v0.2 which only works with CUE. It doesn't use the underlying 0.3 engine. It's possible that we'll launch a future CUE SDK that is a binding to the 0.3 API, meaning it brings breaking changes to 0.2 plans but also feature parity with the other 0.3 SDKs. But that'll depend on demand/interest from the community.

runic heron
#

@fossil pine From the pipeline perspective I'd probably think "that depends on the pipeline", if you're pulling in 10-15 repos of code to form an integration test pipeline and build up a big distribution- having that pull external repos makes a bit of sense.

Currently from what I've seen of the (fairly simple) examples - by pulling from an external repo - you can quite easily change that and pull YOUR repo in the build and play with - without actually touching your repo and putting dagger code in there.

#

Right - 11:50PM here - I should sleep! More dagger playing tomorrow...

rain oriole
# rain oriole <@106011395186790400> The future of the CUE SDK will depend on demand. The one t...

By the way, there is work currently to port the engine on the current CUE SDK to 0.3: https://github.com/dagger/dagger/issues/3121, but still keeping the same definitions for compatibility. So this'll be the next version for CUE and it's already underway. What I said above was yet another version that more closely matches the underlying Dagger API that the other SDKs are using, i.e., lighter bindings, codegen'd.

sharp oracle
solar bison
#

Is there already some kind of best-practice guide or a list or projects that are already using the Go SDK somewhere? I'm particularly looking for inspiration regarding if I should put dagger directly as a dependency to my whole project or create a subpackage with its own go.mod file ๐Ÿ˜…

fossil pine
#

@runic heron I guess it's fine for examples, but in a real world scenario I'd want to run the pipeline on my local copy.

solar bison
warm temple
hoary spoke
rain oriole
wraith niche
hoary spoke
# wraith niche core/integration/container_test.go:73 is what I used recently (sorry on my phone...

Do you think this can be considered a viable way ```
package file

import (
"context"

"path/filepath"

"dagger.io/dagger"

)

type WriteFileOpts struct {
Path string
Content string
}

func WriteFile(ctx context.Context, client *dagger.Client, ctr *dagger.Container, opts WriteFileOpts) (*dagger.Container, error) {

dirPath := filepath.Dir(opts.Path)
fileName := filepath.Base(opts.Path)

container := ctr.Exec(dagger.ContainerExecOpts{
    Args: []string{
        "mkdir", "-p", dirPath,
    },
})

_, err := container.ExitCode(ctx)

if err != nil {
    return nil, err
}

dir, err := container.Directory(dirPath).WithNewFile(fileName, dagger.DirectoryWithNewFileOpts{
    Contents: opts.Content,
}).ID(ctx)

if err != nil {
    return nil, err
}

container = container.WithMountedDirectory(dirPath, dir)

return container, nil

}

swift inlet
swift inlet
elfin frigate
river swift
#

anything obviously wrong for building a Dockerfile?

    app, err := workdir.Read().Directory("app/").ID(ctx)
    if err != nil {
        return err
    }
    runtime := client.Container().Build(app)

getting input:1: container.build failed to read dockerfile: open /tmp/buildkit-mount3832100689/Dockerfile: no such file or directory ... the directory does contain a Dockerfile locally

royal oak
#

hey all. this is perhaps one of those obvious things โ€ฆ is there a list of cloud providers that I can publish the artifact to, via the sdks? or how do I handle the publishing/delivery step if I am building for a managed service like Azure Functions?

winter linden
royal oak
#

others, for example to deploy to Azure Webapps you package a specific zip, then trigger the deployment to a slot, test it, then swap the slot with production to deploy.

#

specifically I am looking to streamline our azure devops pipelines. they handle our dotnetcore services, nextjs front end, and integration with some SAST tooling as part of the CI pipeline. we then publish the artifact (a zip file), which triggers the deployment pipeline that publishes to azure.

#

Iโ€™m not sure if this is the intended use case for dagger, to simplify all the yaml required so I can do local tests of the pipelines.

chilly arch
#

@hereJoin our Community Call tomorrow at 10 am PDT. @warm temple will give a demo that will be using the new Go SDK, and Iโ€™m looking forward to discussing and learning more about all of the use cases that Iโ€™ve seen pop up in this general channel! Save the meeting to your calendar with the link below:

https://discord.gg/E9cZRraj?event=1034224930943930490

**If youโ€™d like to add a demo, topic or question to the agenda, please add it here. See you there! https://docs.google.com/document/d/1-6RSWHwFoZr588kftPLVvT1RCHUrOrnmURldBRrP1Ak/edit#
**

runic heron
#

oooph - thats 6am my time ๐Ÿ™‚

chilly arch
runic heron
chilly arch
# royal oak Iโ€™m not sure if this is the intended use case for dagger, to simplify all the ya...

@warm temple @slender star should be able to help you, @royal oak. They are at KubeCon right now, so just a heads up that there might be a delay. I did create an issue to create a guide for your use case though! https://github.com/dagger/dagger/issues/3570

GitHub

Discord Context others, for example to deploy to Azure Webapps you package a specific zip, then trigger the deployment to a slot, test it, then swap the slot with production to deploy. specifically...

teal oar
#

FrogeWave hello all! Found this today and it seems super cool! I was curious around how itโ€™s expected to run. IE say I have a CI pipeline using Concourse or GitHub Actions, generally these are already ran using containers and usually to kick off the job they clone the repo theyโ€™re watching. I noticed the docs have you cloning the repo right off the bat and then booting up a container to do work. Is there any guidance around the things I mentioned above?

royal oak
#

I think what you are asking is, how to run the dagger pipelines from a github trigger? Not sure I understood your question - and I think I may have the same one, so just want to see if we are both talking about the same thing.

runic heron
#

In case I don't make the zoom call in the morning - I put up a quick screen cast of my experiments with GoSDK - only.... I forgot I switched to a 4k screen this week and erm, it's a bit small fonty (I did zoom in post-prod but may re-record eventually ) - does https://share.descript.com/view/1SXwOgfaC1M work for people?

#

(of course - I also forgot to RUN the pipeline in the demo, but since I was zooming in you'd probably not see that anyway ).

slender star
runic heron
#

Cheers!

placid briar
#

For what little it's worth, I hope the cue interface is maintained and put forward; I rather like the idea of describing the workflows as DAGs in "just data", and once my brain got wrapped around cue, I'm fairly sold on it as a configuration language. Mixing that with code doesn't seem as elegant to me somehow.

Not to mention I now have invested a decent amount in building some configurations and I'd prefer they not rot!

teal oar
smoky bobcat
#

so... I want to build Docker images using nix inside a container, which results in a docker loadable tarball inside a container when used in docker.#Build, how can i 1) extract that file as an Image 2) build it directly in a specific container?

chilly arch
runic heron
rain oriole
runic heron
# rain oriole Python now has structural pattern matching (https://peps.python.org/pep-0636/), ...

There is some deep fu that comby can handle with sub expressions/patterns, which are more useful when using the recipe files which offer a much larger set of rewrites - I did just spot https://pypi.org/project/comby/ which is a python wrapper for it too - such as (sorry for the Java):

[change-dataprovider-definition-to-junit]
match='''
@DataProvider
public Object[][] :[name] {
  return new Object[][] {:[args]};
}
'''
rewrite='''
public static Stream<Arguments> :[name] {
  return Stream.of(:[args]);
}
'''
rule='''
where
rewrite :[args] { "{:[v]}" -> "arguments(:[v])" }
'''

That has a basic top level match, but then an inner "rule" to also rewrite the argument structure. Google has something similar with their refaster templates and tooling for C and Java - I wonder if they already have something similar for Go somewhere.

pulsar sigil
winter linden
# pulsar sigil I agree, and I second this. I think being able to define pipelines in a programm...

I understand and we intend to keep maintaining it.

Note however that the new SDKs are all built on an underlying API which is declarative. When you are querying the dagger engine you are actually sending a graphql query describing the data you want to see. Technically you query is not executed it is resolved. The result of each operation could be generated if needed, or retrieved from cache.

the breakthrough that makes these new SDKs possible is that we found a way to decouple this declarative DAG model from Cue and move it into a language-agnostic API.

So if anything, the DAG model that drew you to Dagger is only getting stronger: it can now โ€œinfectโ€ an imperative language with a declarative parasite ๐Ÿ˜

cc @placid briar

teal oar
#

Are there any docs on actually running a dagger โ€œengineโ€? Iโ€™d like to look into using dagger but the lack of documentation leaves me hesitant.

swift inlet
teal oar
#

I have no idea, hence the confusion. You see references in the Go SDK docs "querying an existing dagger engine" but no reference to what that means. So that's also my question, what is the "dagger engine" how do I run it? Is it in the SDK?

#

Ignore that sticker, that is def not what I wanted lol.

runic heron
teal oar
#

"Using the SDK, your program opens a new session to a Dagger Engine: either by connecting to an existing engine, or by provisioning one on-the-fly."

https://docs.dagger.io/

And then no where is it defined what the "engine" is. You get pictures of where it's at in the flow (attached). This makes me think something is running constantly listening for calls which might answer my previous question of how to integrate this into actual pipelines.

runic heron
teal oar
#

So is it possible to just run a server for dagger that only handles calls?

runic heron
#

Not sure on that - afaik there's still the dagger CLI tool - so I guess that may take the place of that server... I'm just a pleb user my knowledge is limited as well

winter linden
#

@teal oar we are intentionally vague because the engine is not yet consumable as a single โ€œthingโ€ that you can run and connect to. But that will change soon. In the meantime there are individual pieces that you can look at and run, but I would only recommend doing that if you specifically want to dive into the internals

winter linden
winter linden
winter linden
swift inlet
winter linden
teal oar
#

catthinking So mainly right now it's meant to be ran locally which I still have problems understanding how you'd use it in a system such as GithubActions, Concourse, or other CI engines that use containers by default other than doing Containers in Containers.

swift inlet
winter linden
swift inlet
teal oar
#

Gotcha ๐Ÿ‘, last but not least. Since most build scripts are located with the actual code I'm guessing a common pattern is to just do something like go run dagger.go (or w/e you called your script)?

swift inlet
winter linden
teal oar
runic heron
#

Anyone got any examples of using private github repos? Simply adding the env var with my token to the container didn't work - as I guess the Git call/declaration runs separate from that.

swift inlet
runic heron
#

0.3 gosdk

swift inlet
# runic heron 0.3 gosdk

I am pretty sure that we are passing your ssh-agent key to the operation. Run locally: ssh-add, then run your go code.
(currently testing in parallel)

swift inlet
# swift inlet I am pretty sure that we are passing your `ssh-agent` key to the operation. Run ...

Yes, that's it:

โžœ  ssh-add -D
All identities removed.
โžœ  go run .                                                                                                                  
panic: input:1: git.branch.tree.file.contents failed to load cache key: failed to fetch remote git@github.com:grouville/privateExample.git: exit status 128

Please visit https://dagger.io/help#go for troubleshooting guidance.

goroutine 1 [running]:
main.main()
        /private/tmp/git/main.go:20 +0x61c
exit status 2

After:

โžœ ssh-add
Identity added: xxxxx
โžœ  go run .  
readme #

=> Adding it tomorrow to the FAQ ๐Ÿ™

runic heron
#

Ahh! Why didn't I think of ssh agent ( i rarely actually use it ) as I'm usually just in my direct shell space.

turbid tulip
chilly arch
swift inlet
heavy karma
chilly arch
heavy karma
#

If making it a guide, I suggest creating a node named Guides in the Go SDK category nav tree, similar to what we have for CUE already, and using that as the default location for short guides for the moment.

chilly arch
#

@here you can now access the community call recordings from our Dagger events page. I have updated the Oct 27th tile with the recording from yesterday. Take a look!

We had great demos from @warm temple and @runic heron ! https://dagger.io/events

earnest osprey
runic heron
chilly arch
frozen basin
#

Hey yall - curious if tracing still works? I thought at some point early on I was able to see build step, duration, etc in jaeger, but I was tinkering with tracing a couple times last week, didn't see much in jaeger.

turbid tulip
#

I'm not sure what the current status of that is.

#

It looks like setting the environment variable OTEL_EXPORTER_JAEGER_ENDPOINT to a Jaeger endpoint should send traces to it.

frozen basin
#

fasho ty!

chilly arch
#

@here just a reminder that our community call is this Thursday at 10 am PDT. You can add it to your calendar with the link below. If you have any demos, topics, or questions that you want to add to the agenda, please let me know.

See you there! https://discord.gg/ZJdxVN5w?event=1035644790827647067

chilly arch
#

If you missed the community call last week, you'll want to check out this monorepo demo that @warm temple did. You can see the specific clip here -https://youtu.be/vJfoyN77fo0

Join Kyle as he demos how to manage monorepo dependencies with Dagger in under 10 minutes. He did the demo live from KubeCon during a Dagger Community call, so excuse the background noise.

Check out the hello-monorepo example here:
https://github.com/kpenfound/hello-monorepo

โ–ถ Play video
fossil pine
#

Thinking about submitting a talk about Dagger to KubeCon EU. Also, there is a Nix vs Dagger comparison in my blog post queue. Just FYI ๐Ÿ˜„

wraith dove
#

Hello my name is Angel Rivera and I'm very interested in learning more about dagger and que projects. I'm currently a Developer Advocate for CircleCI and interested in learning about and assisting in how to better integrate/leverage dagger within the CircleCI and other continuous delivery platforms. I look forward to learning and contributing where ever possible. If there are any questions regarding CircleCI please feel free to ping me. Thank you

slender star
#

Hello my name is Angel Rivera and I m

chilly arch
chilly arch
#

@hereCalling all Python users! We are looking for testers willing to try an early version and give us direct feedback before officially launching. If you would like to test and provide feedback this week, please comment on the thread below and I will reach out to you directly.

#

Python Early Access Requests

chilly arch
#

@here Shout out to the Python users! Tomorrow's community call will have a demo from @rain oriole to show the latest Python SDK developments. You can find the details for the community call here. See you there! https://discord.gg/ZJdxVN5w?event=1035644790827647067

If you want to get early access to help us test before launch, please let me know in the thread above.

slender star
#

@balmy orbit โ˜๏ธ

frozen basin
turbid tulip
rain oriole
winter linden
#

copyright 2012

#

damn

#

last update 2012

#

maybe we can get it, but not next week

elder nimbus
#

Unable to install dagger sdk with go install dagger.io/dagger@latest on mac. getting error: go.mod file found replaceable directives.

winter linden
#

it is annoying but necessary, for now..

elder nimbus
#

ok let me try

elder nimbus
#

worked adding go mod edit first and then go install.

winter linden
elder nimbus
#

no problem another issue is with cue sdk, the documentation doesn't indicate how to get it?

winter linden
winter linden
elder nimbus
heavy karma
heavy karma
elder nimbus
#

works on chrome ! on safari doesn't show up

heavy karma
#

Do you not see the tabs @elder nimbus?

#

I've checked on firefox/linux, firefox/windows, chrome/windows and chrome/android and the tabs show up in all those. I don't have safari so can't check there, sorry!

winter linden
#

looks fine on safari (Mac OS) for me

elder nimbus
#

Anyways got cue installed.

heavy karma
#

So two issues:

  • social link sharing doesn't show the correct page snippet (might be only in Discord though)
  • tabs don't show up in safari in some cases

I'll open issues for these and @elder nimbus I will ping you to collect some info on your safari and OS version in the ticket so I can check up on this further.

heavy karma
chilly arch
#

Just a heads up that zoom says that the community call recording from yesterday is still processing. I submitted a zoom support ticket. Hopefully, I will have the recording for y'all soon! cc @wraith niche

wary peak
#

Hi all! I'm looking at dagger and loving the prospect of replacing error prone ci scripts with Go.

I'm trying to understand where exactly it fits, though. If i were to use the Go SDK, is the expectation that Circle CI, for example, will only have 1 step that runs my dagger program and that's all?

Before the Go SDK released my assumption was that Dagger is supposed to generate that config for me, but now that seems like a non-goal, is that accurate?

Thanks!

winter linden
#

Did anyone watch Nic Jackson's live stream yesterday? I'm watching the recording now ๐Ÿ™‚

https://www.youtube.com/watch?v=PD8e1rDyUMo&t=1s

Apologies with the quality of the later half of this Video, my computer started misbehaving for reasons eating up all of my GPU resources which are used to encode and stream video. Even the recording is broken. I will re-record this tomorrow evening and get a new copy uploaded.


In the last session, we built our application and pushed it...

โ–ถ Play video
winter linden
quaint jasper
#

Hey all! Really excited to use Dagger when the Python SDK comes out, it ticks all of the right boxes for me!

Just one quick question that could perhaps be elaborated a bit in the documentation: Dagger has a client-server architecture, but I am not sure that I understand what the implications of this are. Is it possible, for example, to have a build agent running remotely somewhere that you can then run stuff on with a client? When is the server started?

Please excuse my ignorance. As I said, the tool looks absolutely amazing. Can't wait to make this a core part of my CI/CD pipelines.

rancid canyon
#

Hi folks I had a few problems with the live recording of part2, but I recorded it again last night and pushed up a new video

#

I am loving the updates to dagger 0.4, the directory updates make things super easy to use

#

One question I have for you all is do you plan to somehow abstract the concept of cache so that I have a way to store it and later retrieve it when the machine might be different

#

I was thinking that maybe cache could be stored in an image then it could be pushed and pulled from a registry

#

Being able to push the CacheVolumes to a remote place could be cool

#

That would make working with things like Terraform way easier, I could manage the state in a pure dagger way.

jagged flicker
#

Hi ๐Ÿ‘‹
Just quick intro first, Iโ€™m a senior software engineer at Docker, working on Hub services for publishers (official images, verified publishers, open source program).
I played a bit with dagger and wanted to share with you what I tried. Especially I have not idea if Iโ€™m doing it โ€˜the rightโ€ way, or maybe thereโ€™s easier ways to do it. Let me know ๐Ÿ™‚ (details in ๐Ÿงต )

vestal creek
chilly arch
#

The zoom recording of the Nov 3rd Community Call finally finished processing. You can see the recording below or on https://dagger.io/events. In this recording, you can see the latest demo of the Python SDK. If you are interested in trying it out before we officially launch it, please let me know!
recording - https://dagger-io.zoom.us/rec/play/0Tg_BdAPeBFlxOL-ICqStDVgXYE0CtoH0MzwPzTvlBa6luEGQ4AneViJWrXmyTgI8YyWoET0GpYO10jr.QUClEurUynq4CJdV?continueMode=true

winter linden
#

Cache management

winter linden
frozen basin
#

Hey yall - curious if kotlin/java sdk is on the roadmap at all?

I'm imagining a gradle plugin similar to jib but backed by dagger could be quite powerful

chrome vessel
#

Is it possible to develop actions in go and the pipelines in cue?

chrome vessel
#

Any plans on making a dagger buildkit frontend? I would love to have the option to use dagger instead of a Dockerfile and not break local development workflows that build images with docker-compose and docker build.

chilly arch
#

Hi all! Check out @warm temple's latest Dagger Go SDK 0.4 "Getting Started" Video - He highlights the big features of the latest release in a quick tutorial -https://www.youtube.com/watch?v=0fSzOOZ2CO8

The Dagger Go SDK contains everything you need to develop CI/CD pipelines in Go, and run them on any OCI-compatible container runtime.

In this video, Kyle will walk you through how to use it.

Who is it for?

The Dagger Go SDK may be a good fit if you are...

  • A Go developer wishing your CI pipelines were Go code instead of YAML
  • A developer...
โ–ถ Play video
chilly arch
#

@rancid canyon has done an amazing job at showing how to use Dagger in real-world scenarios. Don't forget to click "notify me" for his next livestream, which is scheduled for Nov 13th at 11:00 am PDT. https://www.youtube.com/watch?v=eCKes2AKzK8

So far we have learned how to compile and package our application with Dagger, and how you can deploy this application using the Terraform CDK. In this episode, you will learn how to make your Dagger pipelines dynamic and how you can run them in GitHub Actions.

Learn with me as I use the new Dagger SDK to build a simple Go microservice and depl...

โ–ถ Play video
winter linden
#

Buildkit frontend

chrome vessel
#

What is the golang equivalent to core.#Start and core.#Stop?

jolly needle
#

@slender star ๐Ÿ‘‹ thanks a lot for your Jenkins and Dagger talk at DevOps World!

swift inlet
#

core.Start

jolly needle
#

I actually wanted to join the community call and to share some of my experiments and ideas about Dagger observability and Dagger&Jenkins&Keptn integrations, but I've been unable to do so due to the OpenSLO meeting conflicts. Will try to join or to share asynchronously in this chat later

timber sphinx
#

@heavy gazelle just got quoted live on GitHub actions universe ๐ŸŽ‰

chilly arch
#

Hi Dagger Community! We have some great demos planned for tomorrow's community call, so don't miss it. We'll showcase the Python SDK, preview the NodeJS SDK, and get some insight into how @rigid epoch's Dagger hackaton for work went - https://discord.gg/UhXqKz7SRM?event=1035645348372283472

slender star
# jolly needle I actually wanted to join the community call and to share some of my experiments...

Learned about this project from @jolly needle today during talk. Very cool! Imagine I might use to test running Dagger pipelines run from a Jenkinsfile. https://github.com/jenkinsci/jenkinsfile-runner

GitHub

A command line tool to run Jenkinsfile as a function - GitHub - jenkinsci/jenkinsfile-runner: A command line tool to run Jenkinsfile as a function

swift barn
#

what was the reason that dagger has been renamed to dagger-cue?

winter linden
#

(release planned next week)

sage prism
#

What is the future vision of CUE in the Dagger world?

winter linden
#

Future of CUE & Dagger

chilly arch
chrome vessel
#

Is there a way to load an image into docker from the go sdk? Like the docker buildx --load flag?

pseudo stream
# chrome vessel Is there a way to load an image into docker from the go sdk? Like the docker bui...

Yeah we actually have to do that in some of our internal tooling, so there's an example here: https://github.com/dagger/dagger/blob/c432581c36a481bbc86ab7f340a9365e2c6a26b0/internal/mage/util/util.go#L142-L175

The idea is basically to do an export of the image as a tarball to the local filesystem and then shell out to docker to load it. So not the most elegant thing in the world but gets the job done.

chrome vessel
#

Are there any docs on cross sdk actions? I see dagger.Serve in the examples and I'm curious if thats is for cross sdk actions, how that works, and how to consume it.

chilly arch
pulsar sigil
#

Awesome! I will take a look!

chilly arch
rigid epoch
#

apropos of nothing in particular, whoever's making the art for your blog posts is doing a great job, love these sneks

silver bay
winter linden
silver bay
#

Thanks @winter linden . What should I do? Raise an issue on Github?

winter linden
tardy mauve
#

We had a fantastic community call today

stable oar
#

Hey - congrats on the python release - spent 20m kicking the tyres yesterday and it worked really nicely! Im not sure if I missed it in the docs but I wanted to get an idea of how dagger deals with docker in docker. Is there somewhere I can read up on that?

e.g. some of our Github actions use docker-compose to run end to end tests. Im assuming this would not work in Dagger? If so, what's the suggested way of doing this?

dark wave
#

So one thing that appealed to me about dagger earlier on was the composition of workflows and the ability to provide inputs at various places.

ie. https://github.com/dagger/dagger/blob/v0.1.0/docs/learn/1004-first-env.md#configure-user-inputs

Looking at the pivot to typed SDKs - is that ability gone and I need to program it manually?

GitHub

A programmable CI/CD engine that runs your pipelines in containers - dagger/1004-first-env.md at v0.1.0 ยท dagger/dagger

real kite
#

Been playing with the python sdk a bit... Just wanted to check, because it seems that way, multi-stage builds that are composed in code like with cue (https://docs.dagger.io/1205/container-images/#multi-stage-build) are currently not supported in the Python SDK, correct? I would need to use Dockerfile instead?

You can use Dagger to build container images, either by executing a Dockerfile, or specifying the build steps natively in CUE. Which method to choose depends on the requirements of your project. You can mix and match builds from both methods in the same plan.

sharp marsh
# real kite Been playing with the python sdk a bit... Just wanted to check, because it seems...

๐Ÿ‘‹ welcome conor! having "multi-stage" like builds in dagger is definitely possible. Here's an example with the Go SDK that does exactly this. https://github.com/kpenfound/dagger-demos/blob/main/go/getting-started/ci/main.go#L107-L141

You'll notice how the binary gets built with the golangImage and then copied to a baseImage container that gets published into a registry. Since the python API has the same form as the Go SDK, translating between the two should be strightforward. Let us know if you have any other questions!

sterile mason
#

Hello everyone, I was exploring dagger along with go SDK in general, is there any UI to visualise the pipeline as of now?

slender star
slender star
#

Hey congrats on the python release spent

slender star
#

@rancid canyon Excited for your live coding today in a little over an hour: https://www.youtube.com/watch?v=eCKes2AKzK8

So far we have learned how to compile and package our application with Dagger, and how you can deploy this application using the Terraform CDK. In this episode, you will learn how to make your Dagger pipelines dynamic and how you can run them in GitHub Actions.

Learn with me as I use the new Dagger SDK to build a simple Go microservice and depl...

โ–ถ Play video
rancid canyon
#

Thanks, I am actually just trying to debug a weird thing, seems like clients file system is snapshot on connect

#

that is stopping me do a build with an asset from another step

slender star
#

Ah, interesting. Can you make a new call for the client host workdir?

rancid canyon
#
    golang := client.Container().From("golang:latest")
    golang = golang.WithMountedDirectory("/src", src).
        WithWorkdir("/src").
        WithEnvVariable("CGO_ENABLED", "0")

    golang = golang.Exec(
        dagger.ContainerExecOpts{
            Args: []string{"go", "build", "-o", "build/"},
        },
    )

    path := "build/"
    err = os.MkdirAll(filepath.Join(".", path), os.ModePerm)
    if err != nil {
        fmt.Printf("Error creating output folder: %s", err)
        os.Exit(1)
    }

    build := golang.Directory(path)

    _, err = build.Export(ctx, path)
    if err != nil {
        fmt.Printf("Error writing directory: %s", err)
        os.Exit(1)
    }

  client.Close()
    client, _ = dagger.Connect(ctx, dagger.WithLogOutput(os.Stdout))

  buildDir := client.Host().Workdir() 

  _, err = client.Container().
    Build(buildDir).
        Publish(ctx, "nicholasjackson/dagger-example:latest")

    if err != nil {
        fmt.Printf("Error creating and pushing container: %s", err)
        os.Exit(1)
    }
#

The only way I can get the build directory that I export is to close and re init the client

slender star
#

@sharp marsh โ˜๏ธ

rancid canyon
#

I probably did not spot this before as I already had that folder but it appeared on ci

sharp marsh
#

@rancid canyon this is to reproduce something like multi-stage build, correct?

#

IIUC

rancid canyon
#

No just plain single arch

sharp marsh
rancid canyon
#

Oh I wanted that file for testing

sharp marsh
#

basically use WithMountedFile or WithMountedDirectory and reference another from a different pipeline

rancid canyon
#

Also build I think needs to run from the context

#

I tried the publish approach like you have it too, I was getting no joy with that

#

let me try that again

sharp marsh
rancid canyon
#

That works if I just do a publish not build

#

that is actually neater, weirdly it seem the position of WithEntrypoint matters

sharp marsh
rancid canyon
#

Yes thank you

sharp marsh
#

โค๏ธ

#

awesome. Feel free to ping if you run into any other weirdness

#

We'll follow up on the entrypoint thing

rancid canyon
#

I really like the publish from container and no dockerfile, had not figured out how to do that so this is cool

sharp marsh
#

๐Ÿš€ new content for the stream

rancid canyon
#

yes, ty

#

Now I need to feed the dog and get ready

sharp marsh
rancid canyon
#

I normally don't leave these things so late but I have had to work all day

pliant owl
#

Hello wonder if anyone could help me - I was taking a look at the Dagger Go SDK and have also looked at CLI. How do these two fit together as the CLI uses CUE? Do you use one or both somewhat confused ๐Ÿ™‚

winter linden
pliant owl
winter linden
#

not exactly, in Go the CLI is optional: you write a regular go program, using dagger as a library, and run that

#

You can basically ignore the CLI for now

pliant owl
wispy wave
#

this weekend, I started to migrate some recipes written in CUE to the GO SDK.it's a quick thing, to see what it might look like. I migrated only 2 recipes. but I'm a feedback taker. for to know if people might be interested in having this level of abstraction?
https://github.com/guiyomh/dagger-sheath-go

GitHub

Contribute to guiyomh/dagger-sheath-go development by creating an account on GitHub.

shrewd wharf
wary peak
#

Is there a Go example somewhere of a pipeline that uses multiple containers and shares files / directories between them? The way I'm writing it right now I lean towards exporting files onto the host and then mounting them when needed.

But I was hoping I could reuse the *dagger.Directory type

tardy mauve
#

Before I go down this ๐Ÿฐ ๐Ÿ•ณ๏ธ further, is there a known issue where mounting /var/run/docker.sock into a container does not work with the Go SDK? It returns an ERROR: error from sender: open /run/containerd: permission denied but it works fine with the docker cli e.g. docker run -v /var/run/docker.sock:/var/run/docker.sock docker docker run nginx sort of thing. This also worked when I used the Cue option, but that was a long time ago.

tardy mauve
#

Before I go down this ๐Ÿฐ ๐Ÿ•ณ further is

rain oriole
pulsar sigil
#

Yeah! I'm playing with it a bit

#

Its really cool

#

I've got some fires I'm fighting but I intend to give this a proper shake down very soon

rain oriole
chilly arch
#

Hi Dagger Community! if you'd like to be a Node.js SDK tester, please DM me. We just completed the Getting Started Guide, so we are looking for users who have some time to test it out today and/or tomorrow.

timber sphinx
#

Could we get a releases channel for just release github/general release notification? Iโ€™be been swamped and itโ€™s hard to sift through all the significant changes. Iโ€™ll probably dig back through github release notes too but thought it might be useful ๐Ÿซก

winter linden
sharp marsh
timber sphinx
chilly arch
chilly arch
wraith niche
chilly arch
rich cairn
#

Hello Dagger! We have a Java server app and our integration tests spawn docker containers (to test LDAP connectors). Can we still use Dagger? I mean, would it mean we'll have a container inception?

sharp marsh
# rich cairn Hello Dagger! We have a Java server app and our integration tests spawn docker c...

๐Ÿ‘‹ there's currently 3 ways to achieve this:

1 - You can start your containers before calling your dagger pipelines
2 - You can mount the dagger docker socket and make dagger call your docker daemon to start your containers
3 - Use the dagger services to handle service initialization in Dagger

Only 1 is possible at this moment since 2 and 3 are in the works and should be ready soon

trim canyon
#

Is there somewhere on the doc that tells me how to trigger a dagger script on a git push?

sharp marsh
trim canyon
#

Thanks!

#

And yeah, sorry, Hi all!

sharp marsh
trim canyon
#

Yup! mostly i'm evaluating some build platforms for a project i'm doing and I like dagger cause I don't like doing my pipeline in yaml or groovy but the triggering part is... annoying

#

having to use another tool for that

#

is there a roadmap somewhere? Are triggers something that's in the scope of the tool?

slender star
#

Hi ๐Ÿ‘‹ could you describe more how you'd like this to work? From your local dev environment, from Git server, from CI tool. Which CI tools do you use today?

#

Guessing Jenkins, since Groovy is in the mix.

trim canyon
#

nah, right now I'm on gitlab using its CI to build a docker image and to store it in a registry

#

id like to be able to have a git server on which I push my files with my "dagger.py" script.
On every push, dagger would run the script

sharp marsh
chilly arch
half relic
#

@chilly arch do we know if a c# sdk is on the roadmap?

winter linden
swift barn
#

hi guys, is it possible to avoid having an env var exposed within the dagger project codebase (e.g. container.WithEnvVariable in main.go) somehow by inserting it as a docker run -e parameter for example?

winter linden
#

Avoiding exposing env variables

winter linden
#

@half relic we just got a demo by @verbal canopy of a Powershell client, which is (I think?) a first incremental step towards an eventual c# SDK given the common .net DNA

half relic
winter linden
chilly arch
verbal canopy
winter linden
#

By the way @verbal canopy , is there something we should do for the dagger CLI to work well with powershell?

That CLI works great for bash scripts - would make sense to make it powershell-friendly too?

winter linden
#

Merged but not yet released ๐Ÿ™‚

verbal canopy
winter linden
#

well 0.2 was cue specific ๐Ÿ™‚

#

the graphql part changes things

verbal canopy
#

This syntax won't work.

dagger query <<EOF
{
  container {
    from(address:"hello-world") {
      exec(args:["/hello"]) {
        stdout {
          contents
        }
      }
    }
  }
}
EOF

But I assume a powershell here-string will work fine.

#

Writing non-errors to stderr is not ideal

pseudo stream
pseudo stream
verbal canopy
pseudo stream
sharp marsh
#

good catch. Wasn't thinking about Windows for this example. I'll double check this

sharp marsh
pseudo stream
trim canyon
sharp marsh
trim canyon
#

yeah, that's it

sharp marsh
trim canyon
#

yup

#

well, a VPC but yeah

sharp marsh
# trim canyon well, a VPC but yeah

perfect. Well, yeah.. we don't have "webhooks" integrations natively since dagger is not currently designed to run as a long living engine ATM. Having said that, what you can do is to deploy a sidecar webhook receiver (https://docs.gitlab.com/ee/user/project/integrations/webhooks.html#create-an-example-webhook-receiver) along side your dagger server so each time gitlab sends you this webhook, you can do what you need there.

I know it's not the most amazing experience, but it shouldn't be complex to setup

trim canyon
#

yeah, that's about what I was planning! Shame dagger doesn't do it itself

#

is it out of scope for the tool or can we expect it at some point in the future?

winter linden
#

I think @cloud canyon has some ideas incubating along these lines ๐Ÿ™‚ Native handling of events etc.

trim canyon
#

ooh, nice!

winter linden
#

It's a natural progression from "everything is platform-specific" to gradually shrinking the platform-specific parts, and growing the cross-platform part (in this case using Dagger)

cloud canyon
chilly arch
trim canyon
ocean pelican
#

Hi! dagger looks very interesting. Where can I find a roadmap?
Do you have plan to add C#\dotnet SDK?

winter linden
#

We will soon release an API which you can use to target Dagger from any language, without having to wait for an official SDK

#

Thatโ€™s a matter of weeks. Then youโ€™ll be able to program Dagger with dot net, just will be a less polished experience until the full SDK arrives. Cc @verbal canopy who is doing exactly that with powershell at the moment

swift barn
#

Rust sdk is on the way?

winter linden
verbal canopy
formal token
#

How should I be setting up the buildkit daemon to support custom CAs for image pulls? I notice the FAQ docs on dagger docs have vanished since the great sdkification

chrome vessel
#

Are there any docs on cross SDK actions? I see dagger.Serve in the examples and I'm curious if thats is for cross SDK actions, how that works, and how to consume it.

winter linden
winter linden
chrome vessel
rigid epoch
#

apropos of nothing in particular: I've been learning about Tilt this week, and I feel like it (or maybe something like it with a slightly different API) would pair really well with Dagger. Specifically in the sense that Tilt revolves around tracking k8s resources and continually updating them with the output of a quick build process: that mental model seems like it would be extremely powerful in the context of a framework where lazily-built containers and directories are first-class objects.

#

I've had this sense generally that Dagger could have a powerful role in development-time builds, but seeing Tilt gave me a much better idea of what DX I'd want there.

winter linden
#

That makes sense @rigid epoch , especially since (I believe) tilt uses buildkit, so it could even be ported to actually use dagger ๐Ÿ™‚

Thereโ€™s also okteto that I believe is a direct alternative to tilt

tall gulch
winter linden
#

Each article has a unique random ID precisely to avoid breaking URLs. I agree we should add warnings when an article is no longer correct in more recent versions of dagger, like this particular article. Weโ€™re working on that.

Versioning the entire docs introduces its own problems, doing it article by article gives is more flexibility

timber sail
#

I was looking for a place to say this, and still not quite sure, but I'd like to thank the dagger.io Go SDK dev team members because this allowed us to build a completely testable CI pipeline (our previous CI pipeline was using GitHub actions, but as our CI implementation gets bigger, testing it before releasing it was practically becoming impossible). Thank you, team!

rose ermine
#

Heyo, are there any public examples of using the nodejs sdk and github actions?

warm temple
sharp marsh
rancid canyon
#

Yes, I was going to check that out this week but, I was pretty beat after travelling. I think I will do a stream on Sunday

heavy karma
#

Need some help understanding why this nodejs sdk code doesn't work

  const source = await client.host().workdir(["node_modules/", "ci/"]).id()
  const node = await client.container().from("node:16").id()
  const c = await client
    .container(node.id)
    .withMountedDirectory("/src", source.id)
    .withWorkdir("/src")
    .exec(["npm", "install"])
    .withEntrypoint(["npm", "start"])
const dh = await c
    .publish("vikramatdagger/node")

when published, the container doesn't include the source or the deps

$ docker run -it --entrypoint /bin/sh vikramatdagger/node
# ls /src

Question: Do I need to manually copy the files from the mount point to a location in the container?

warm temple
sharp oracle
#

Are there any sort of deploy docs available? I vaguely remember some parts of 0.2 docs talk about that, but I can't find anything in 0.3's. What I'm specifically interested in, if it can use a remote BuildKit cluster (probably can, given 0.2 did) and how does that affect functionality? For example I would imagine having just BuildKit means dagger won't be able to just run networked containers, right?

slender star
# sharp oracle Are there any sort of deploy docs available? I vaguely remember some parts of 0....

@sharp oracle things are still in progress. Conversations happening in issues like: https://github.com/dagger/dagger/issues/3939

GitHub

What are you trying to do? I'm trying to achieve a workflow where dev machines could spin up dagger engine as the state can shared on buildkit. I would like to avoid using Docker to spin up...

river rock
#

Are there any sort of deploy docs

tough elm
#

Does anybody try the java project? It's stuck. But in GitLab CI runner, it works.

#

Can't get any valuable info for the log

#

It worked in GitLab ci

slender star
tough elm
#

of course

tough elm
marsh ether
#

small question -- the golang SDK looks great, but what I don't understand is how/when I'd care for the graphql API...? ๐Ÿ˜•

elfin frigate
#

@marsh ether (hi!) there's a good chance you would never have to care about it, since it's just the api being used under the hood. you might care about it if you're building an entire SDK or something though

winter linden
#

There are 3 reasons you may be interested:

  1. If you want to program Dagger in a language that doesnโ€™t have an official SDK yet
  2. If you use an official SDK & want to dig deeper, understand the internals, use the API playground to experiment or debug a query
  3. If you want to run pipelines from the terminal or a shell script

Like @elfin frigate said, if youโ€™re in the โ€œhappy pathโ€ using an SDK and donโ€™t fit in the categories above, then you can ignore it.

marsh ether
swift barn
#

How we can use dagger for monorepo? can it replace bazel?

slender star
swift barn
slender star
#

Before the multi-language SDK launches (Go, Python, Node.js), we supported only Dagger with CUE language. Dagger Cloud initially was a way for folks to share their Dagger CUE runs so we could help with debugging, etc.

We'll likely bring back that use case and others like visualizing your pipelines and many others ๐Ÿ™‚

swift barn
#

ok thanks

mystic mantle
mystic mantle
#

We are a monorepo btw, we create subrepos out of our monorepo for some packaging needs, but those clones are read only, and dagger deals with the whole monorepo.

swift barn
mystic mantle
#

Not exactly. It's specific for a few items. Most notably the SDKs.
https://github.com/dagger/dagger/tree/main/sdk/go is its own Go module. Due to some limitation in the Go vanity URL protocol, we had to extract this module in its own repository in https://github.com/dagger/dagger-go-sdk, so when go get-ting dagger.io/dagger, it would get this repo instead. But we don't submit code to this repo, it is just extracted by our CI (https://github.com/dagger/dagger/blob/main/internal/mage/sdk/go.go#L99)

blazing obsidian
#

Hello guys, may be there was a related question already and I missed that, but why don't you use Dagger in your own GItHub repo?

blazing obsidian
swift inlet
dawn patrol
#

Hi dagger team!

I like the approach of Dagger, being independent from any CI/CD solution. I'm trying to understand if it fits our use case:

We have a C++ based project that uses CI and CD by executing the following steps:

  • Install deps (cmake, gcc/clang, git)
  • Clone a git repo
  • Compile via cmake
  • Execute the result to run unit and integration tests
  • Deploy result via FTP

I have not been able to find an example how to do this with dagger though. Is dagger only for Go/Node/Python? I thought about "coding" the CI in nodejs even though the project is based on C++. Is this possible?
I fear that I didn't understand the concept yet. Lets say I have docker installed on Windows, I have the CI and want to create a windows build. How do I "spawn" a Windows image that has a compiler installed and such?

Help is greatly appreciated

swift inlet
#

dagger with c++

vapid stag
#

Its interesting to see magefile pop up in many places in/adjacent to the dagger ecosystem. Do we see magefile or something like it occupying a special place in the dagger golang sdk ecosystem down the road? Or is it more just a case of right tool for the job?

hardy sparrow
#

Is there any way to get the nifty dagger-cue buildx like console output when using the go-sdk?

swift barn
vapid stag
# swift barn Very personal opinion: I do not think Dagger should be opinionated. Integrating ...

For example mage gives a little more structure / guidance around how to organize commands, and provides a more explicit way of modelling dependencies than the golang sdk (albeit not connected with the buildkit deps mechanism which is at the core of dagger). I think with cue, when you look at a pipeline, its like ok yeah here are the steps/stages. With golang and i assume the other language sdks it can be a little less clear.

But im also just curious if there has been any thinking here. The fact that we see the two used in conjunction a fair bit is interesting to me.

swift barn
past ivy
#

I thought dagger was meant to save me from this ๐Ÿ˜‚

sharp marsh
past ivy
sharp marsh
past ivy
sharp marsh
past ivy
#

And then the docker image doesn't have node installed (obviously), but because I was running it through zx it just... did nothing

#

so that took far too long to realise too

heavy karma
#

Yes, I too had a lot of issues getting dind working on a self-hosted Gitlab runner

past ivy
winter linden
#

@past ivy one approach weโ€™re seeing is farming out pipeline execution to a remote dagger host, to remove the need for dind. The gitlab ci runner in that case becomes a dagger client. Is that something you would you consider, now or in the future?

past ivy
slender star
#

Great to see @full geyser at AWS re:Invent in Las Vegas!!

naive obsidian
#

Hello Dagger community ! I'm starting to use Dagger and I have a few questions ๐Ÿ˜

Since languages SDK (Go, Node & Python) are available, do you plan to continue supporting CUE SDK ?

What do you recommend for a team working with different languages ? In order to avoid having our CI conf in multiple languages, does CUE remains a good "standard" option ?

sharp marsh
# naive obsidian Hello Dagger community ! I'm starting to use Dagger and I have a few questions ๏ฟฝ...

๐Ÿ‘‹ welcome Thomas! Yes, the CUE SDK will be supported like any other SDK.

re multiple languages: It really depends on how complex your use-case is and how many people need to interact with those pipelines. We do we have plans to make pipelines be interoperable across languages through what we call "extensions". Having said that, we generally recommend starting with a language you know since that will make the dagger onboarding easier.

chilly arch
#

@here Just a friendly reminder that our weekly community call time slot has changed, and we've made the registration for the calls much easier. The calls will be on Wednesdays at 9 am PST, so we will have one tomorrow. Use the link below to register and easily add it to your calendar. See you there! https://dagger-io.zoom.us/webinar/register/9716685521713/WN_USQjVBGXT0SWhNMvqYVvCA

naive obsidian
#

Hello @sharp marsh, thanks for your answers !

sharp marsh
naive obsidian
past ivy
#

Ah great to see you here @naive obsidian! Enjoy dagger ๐Ÿ˜„

naive obsidian
sinful knot
#

@naive obsidian, we can have a chat about it at the DevOps D-Day ๐Ÿ˜‰

naive obsidian
naive obsidian
chilly arch
wraith niche
chilly arch
chilly arch
#

๐Ÿ‘† As always, we love feedback, so let us know what you think!

merry sentinel
#

So i was looking at dagger awhile back then came back to it yesterday and noticed it seems to have been updated! Which is really cool and love the SDKs. I was wondering if the whole how to use dagger in certain CI/CD platforms is in the past with the SDKs? So like using it in github actions is the same as using it in CodeBuild?

solid wraith
winter linden
#

dagger.json is not currently supported. Itโ€™s an experimental feature still in development (related to extensions primarily)

glad jolt
#

Hmm, no, it should be fixed with a rebase though.

#

Oh, thought we were waiting for input on the graphql query

#

I can merge as is after rebasing

#

Sounds good!

winter linden
slender star
#

@rigid epoch I didn't realize how cool these WandB stickers were until I got home and found some sunlight!! Was great to stop in at your booth at re:Invent ๐Ÿ™‚

warm temple
turbid tulip
#

Hey all! I've been working on the CUE SDK a good deal lately, and I'd love to hear from you all if you're interested in that and potential for the future of Dagger + CUE. I've got a GitHub discussion going here, feel free to join! https://github.com/dagger/dagger/discussions/4086

GitHub

I've gotten a good chunk of work done on a port of the v0.2/Europa API to the v0.3+/multi-language engine. I'd like to: speak to the current progress on that write about the parts o...

swift barn
#

Hi all! I'm wondering if it is possible to use dagger to run pipeline into existing containers (built with docker-compose for example)?
My use case: I have existing docker stacks with docker-compose, but I would like to write pipeline to execute tests suites with Dagger, inside those containers. Thanks for help

wary peak
swift barn
#

I tried this with the GraphQL API, but it wants a ContainerID, not the docker id of the container.

past ivy
winter linden
past ivy
#

Are there any ideas from the dagger side on how parallel execution and multiple builds should be handled? So in a monorepo of microservices, I'd have a build step for each service, which should be run when a service changes, or something it depends on changes (e.g a utility library). Are there any plans or ideas on having dagger help with this dependency graph resolution?

I'd also want to run the builds in parallel, preferably as distinct jobs so it's easy to see from our CI platform (now Gitlab, but hopefully a standalone for dagger in the future) which jobs ran etc

past ivy
#

After a brief walk to refresh my brain, I realised all that I really want at its core is:

  1. Some way to retrieve the DAG of a pipeline execution
  2. Support for re-running and stopping at a given point (this requires building some kind of persistence layer, likely shouldn't be part of Dagger core but some kind of plugin)

Those 2 would allow Dagger to entirely replace classic CI tooling like GH Actions or Gitlab CI/CD

mystic mantle
mystic dune
mystic dune
sharp marsh
chilly arch
river rock
#

Community Call Demos

chilly arch
#

Thanks to all of you for your support as we update the structure of our Community Calls. Many of you have already brought some awesome demos to the calls, and I can't wait to see what you bring to the next ones!

We are moving the Community calls from weekly to every other week. If you haven't already registered, you can do so at the link below. We look forward to seeing you at the next call on Thursday, December 15th at 9 am PST. If you would like to be added to the agenda, please DM me. Register here - https://dagger-io.zoom.us/webinar/register/9716685521713/WN_USQjVBGXT0SWhNMvqYVvCA

cunning jolt
#

Hi @chilly arch I assume there's no call tomorrow?

chilly arch
rose ermine
#

heyo ๐Ÿ‘‹ is there a way to publish a directory to an OCI container registry (as an artifact) using the dagger sdk? I'm specifically using the node.js sdk atm, and I can see that there's a publish method on the Container type in the docs, but can't figure out how I would do the same for a directory.

mystic mantle
# rose ermine heyo ๐Ÿ‘‹ is there a way to publish a directory to an OCI container registry (as a...

I guess you could create a container from scratch and add the directory you want from your build step

const buildDir = client.container()/* โ€ฆ whatever you do here */.directory("/your/directory")
const scratchContainer = client.container().from(/* put nothing to get a scratch container */).withDirectory("/", buildDir, {exclude: [".git" ]})
scratchContainer.publish("docker.io/me/myimage:latest")

(the API for this is based on the NodeJS SDK v0.3.0 which should get out today (notable the exclude part)

rose ermine
winter linden
#

This is generally correct. You donโ€™t need the from part, and you can use withRootFS

#

@rose ermine As a graphql query:

{
 query publishDir($dir: DirectoryID!, $address: String!) {
  container {
   withRootFS(fs: $dir) {
    publish(address: $address)
     ref
    }
   }
  }
 }
}

(field names may be wrong)

errant mauve
swift inlet
errant mauve
#

@swift inlet thanks - will read ๐Ÿ™‚

#

First hurdle, no dagger-go install...

curl -I https://dl.dagger.io/dagger-go/install.sh
HTTP/2 403
content-type: application/xml
date: Thu, 08 Dec 2022 10:42:12 GMT
server: AmazonS3
x-cache: Error from cloudfront
via: 1.1 7b5cd9167634df8189bb5a88ba570ee0.cloudfront.net (CloudFront)
x-amz-cf-pop: LHR61-P5
x-amz-cf-id: MQCFAQAZnwpbe0Ao9G-LO7i79DsbpPF1qTDH5S4RVeFv3jwvly2LCw==
#

So... as I have just 1 day, could learn CUE instead

frozen basin
#

Hey yall - been away from the project for a little, got a quick question re: Magefiles etc.

Will dagger eventually support running tasks natively similar to mage? I think there was some discussion about this a while back. Right now I just use cobra from my internal cli tooling.

The behavior I'm looking for would look something like this

# list tasks in a project
dagger list
# Run a task
dagger run foo
winter linden
frozen basin
#

Got it. Thanks!

timber sphinx
#

I just finished a big final push on migrating a project to a more modern release automation process with Mage and moving it from another org to my companies newer GitHub org.

As I wrapped up last night with a "live tweet" that compromised many memes and text like:

  • here we go
  • watching paint dry
  • no deploy for you. forgot your env var didn't you!
  • no deploy for you! helps to have an aws bucket listed
  • No like CGO and cross compilation
  • etc.... for at least a few hours....

It made me get excited all over again to jump back towards Dagger + Mage and see what magic has been happening. Been so swamped haven't gotten to try it but my goal is Jan is Dagger Month (maybe sooner if I can swing it ๐Ÿ˜€

timber sphinx
empty jay
#

I'm not really happy with current UX after using couple of internal repositories. I'm still thinking ways to improve it. I'm open to suggestion ๐Ÿ˜„

empty jay
timber sphinx
vestal creek
swift inlet
maiden cloud
#

Hi guys. Long time I am not joining here... I am stunned by all the updates/changes that are going on.
I started playing with Go SDK and I was wondering if there is a final goal to ever reach Dagger Cue SDK (formerly Dagger CLI), if it makes sense.
I mean Dagger Cue SDK is really able to create portable Plans and to make them available throughout the various/major CI/CD providers. Will be something like that possible through Go SDK in the future or they are intended to remain separate entities with a different purpose?

winter linden
# maiden cloud Hi guys. Long time I am not joining here... I am stunned by all the updates/chan...

Welcome back! Yes, the goal remains the same as before. The major difference is that you can achieve it without having to learn a new language.

Right now you can already develop a custom CI/CD tool or script in the language of your choice, and share it in a portable way on any CI/CD provider. So, it's already quite similar.

The missing piece is what we call API Extensions: this will allow you to package your own pipelines into cross-language extensions, which can be called directly as GraphQL API calls. In other words: Dagger clients written in any language, will be able to invoke pipelines written in any other language.

In the end the resulting GraphQL schema will replace the CUE plan as the universal entry point for your CI/CD configuration.

maiden cloud
#

@winter linden thanks for clarifying. So how can I make a comparison between what I currently can achieve with Dagger CUE plan + Dagger Cue CLI installed on CI/CD provider (e.g. Github Actions) and what I can write down using an SDK (e.g. GO)?
Because right now I was able to replicate my Plan in the SDK but I am struggling understanding what I can do with that, compared to how powerful is porting my plan to any CI/CD provider by just installing the Dagger CUE client into.
I hope it make sense what I am writing, Maybe I am mixing up concepts and just doing confusion and noise ๐Ÿ˜ตโ€๐Ÿ’ซ

chrome vessel
winter linden
#

For example, for our own CI, we use the Dagger Go SDK. The result is a simple Go program that we can run with go run. Our CI is pretty complex and modular (we need to build and test the core engine, the CLI, and each SDK). So we greatly benefit from organizing the code of our CI in Go. Here is the source code: https://github.com/dagger/dagger/tree/main/internal/mage

GitHub

A programmable CI/CD engine that runs your pipelines in containers - dagger/internal/mage at main ยท dagger/dagger

winter linden
maiden cloud
#

@winter linden that is exactly my feeling. I felt a little bit lost, trying to connect the dots.

winter linden
#

Totally understandable. In a perfect world we would have shipped everything all at once. But re-engineering GraphQL + shipping SDKs was such a massive undertaking, we decided to ship it in pieces to get something to users faster. Now we are dealing with the tradeoff..

maiden cloud
winter linden
frozen basin
# timber sphinx I'd be interested if any of your repos are public to see how you use it for task...

@timber sphinx - I put this little walkthrough together, not full code samples but the concepts are in there I think. If anyone reads and has thoughts I'd love to hear it!

the tl;dr is that I'm planning to just use cobra to kick off a pipeline, and try to use standardized interfaces to execute builds based on language/type.

https://blog.stobias.dev/post/2022-12-12-dagger/

maiden cloud
#

We are digging into Dagger GO SDK... We are debugging the point where the dagger client is calling.
There is a dagger-engine container spawn which is running, that is fair enough.
However the library is using an HTTP client to call an endoint http://dagger
Where this hostname comes from? Meaning how it is resolved and where to?

frozen basin
maiden cloud
timber sphinx
winter linden
#

There is no primary invocation approach. Mage is just one among many ways you could load and run dagger pipelines from the CLI. That is causing some confusion at the moment

chilly arch
timber sphinx
thorn axle
#

Howdy everyone! ๐Ÿ™‚ Quick question, will the community call be recorded and uploaded somewhere?

winter linden
mystic mantle
chilly arch
small obsidian
#

Is there a way to create and access DAG directly? In my project I want to wrap cue and dagger to execute some tasks on the host before and after execution of multiple pipelines in containers. These steps have dependencies among them (as well as dependencies between pipelines). The plan is to define dependencies using something similar to cue flow DSL. Then extract DAG from cue and feed it somehow to dagger to get correct execution order. Based on prior discussions in this channel I've got an impression that cue is getting replaced by GraphQL in dagger. Any ideas on: 1) a way to convert cue definitions into a GraphQL query of the right shape? 2) How to express external steps as nodes in the DAG?

#

basically some parts of the project would need to be build on the host and some other parts in containers.

winter linden
winter linden
# small obsidian Own cue DSL

Great, so you can look at @turbid tulip โ€˜s work for inspiration. He got 80%+ of it working. We were actually considering spinning it out into a separate community project in case you find that useful

winter linden
#

@turbid tulip did you settle on the ideal codename? ๐Ÿ™‚

turbid tulip
chilly arch
chilly arch
#

If you'd like to see the demos as snippets, you can check out our Community call demo playlist here - https://www.youtube.com/watch?v=oKO8WjyxRKY&list=PLyHqb4A5ee1tEgcr7KsNFzQSPN-R3fPs2

During our community call, David Jackson shared his experience trying to implement Dagger into his company's monorepo during his company's hackathon.

Want to join the community call or share your Dagger experience with the world? Sign up here: https://dagger-io.zoom.us/webinar/register/4416686668409/WN_USQjVBGXT0SWhNMvqYVvCA

โ–ถ Play video
real kite
#

Is there an existing pattern for running docker-compose like stuff in dagger? For instance, I have a Supabase app that I want to build and test with Dagger. The easiest (and most production-like way) to do this is by using Supabase CLI, which spins up a local docker-compose instance and exposes some ports. It would be nice if I could spin one of those up with Dagger during my CI build to run tests with

sharp marsh
# real kite Is there an existing pattern for running docker-compose like stuff in dagger? Fo...

๐Ÿ‘‹ conor. Native "services" support is still under design and something that we'd definitely like to add soon. In the meantime, we're recommending users to spin up their dependencies using compose before calling dagger. We know it's not ideal but it's a workaround until we can ship an integrated solution for this use-case.

So basically:

docker-compose up -d <my_services>...
go run my_dagger_pipeline.go
vernal sage
#

Hi. I'm really new to dagger. I don't know if there is a way to execute an xcode build command (to build an iphone app) on dagger ? Using a macos image?? Thanks for the answer

slender star
celest crane
#

Hey guys ๐Ÿ‘‹ I did an introductory conference talk on dagger in november and did a significant part about cuelang (because I like the declarative approach) and only briefly touched the new SDKs. I want to rework the talk for 2023 now and after stumbling upon this note in documentation โ€ža fan of the CUE language, and don't mind using the old Dagger engineโ€œ Iโ€˜m wondering if cuelang is already deprecated? Did I miss something? Thx for clarification

vernal sage
winter linden
#

CUE

slender star
timber sphinx
#

To be clear if I start up a new dagger piepline with Go sdk the interface to Dagger right now is either go run or mage etc. Dagger do and such discovery per prior posts is not working in new SDK at this time right? So dagger is providing me the sdk but not the discovery/execution cli right now correct? Been swamped and not caught up so sorry if this is already answered.

winter linden
#

You can dagger run go run or dagger run mage as an optional convenience

sinful knot
#

how about "yabadabadoo !" ๐Ÿ˜†

vernal sage
# slender star Yep, it's a VM runner. https://github.com/actions/runner-images/blob/main/images...

I've tested the docker osx image on my computer. It is impressive. Just run the command and you have a Mac running on Linux. But it's not really a Mac container its just a Linux container that configure a Mac VM for you using KVM. The host KVM device must be mounted inside the container, and you must proceed to a full macos installation the first launch. And the resulting volume might be quite large (I've not terminated the install to test)

wary cave
#

Does anyone have a sample python build.py they can share quickly that does a simple dockerfile build + push ?

Looked through the docs, but it's mostly about building, not much about pushing or using dockerfile.

#

Also wondering if it's more idoimatic dagger to use DIND to do dockerfile builds ?

sharp marsh
# wary cave Does anyone have a sample python `build.py` they can share quickly that does a s...

๐Ÿ‘‹ this should help out:

import sys

import anyio

import dagger


async def test():
    async with dagger.Connection(dagger.Config(log_output=sys.stderr)) as client:
        python = (
            client.container()
            # build container
            .build(client.host().directory("."))
        )

        # push
        image = await python.publish("ttl.sh/footestdagger:1h")

    print(f"Image pushed {image}")


if __name__ == "__main__":
    anyio.run(test)
sharp marsh
wary cave
#

@sharp marsh perfect, thanks! I tried a few commands but not exactly sure how they all relate. got it working now

sharp marsh
wary cave
#

Yeah I think having an examples for some of the most common basic usecases would be nice. (Dockerfile builds, multi-stage builds, monorepo builds, docker login and pushes etc.)

#

The old cue docs have it but couldn't find them on the Python ones.

sharp marsh
loud briar
celest crane
#

Hi, i have a question about terminology: coming from the cue sdk i'm used to the concepts "plan", "action", "input" and "output". Will these concepts be brought to the SDKs, or is the wording now more aligned to the general "container" terminology?

winter linden
winter linden
celest crane
fossil pine
#

I've submitted two Dagger talks to FOSDEM and both have been accepted.

#

The CI devroom schedule is not public yet.

sharp marsh
tardy mauve
#

๐Ÿ‘‹ I don't think this is possible (yet?? ๐Ÿ˜„), but does Dagger supports pruning its cache? It's pretty useful if you need to re-run steps when developing your pipelines.

Earthly has this feature by dong earthly prune

sharp marsh
#

we have dagger-in-dagger support in the playground ๐Ÿ˜‰ https://play.dagger.cloud/playground/XiV8l-ElLIi. Now we can use the playground to test and ANY SDK with minimal effort ;). cc @winter linden @cloud canyon @pseudo stream @glad jolt @slender star @warm temple @rain oriole @mystic mantle @last pine

You'll also noticed something in that link which is very cool daggerfire

sharp marsh
#

we have dagger in dagger support in

mystic mantle
#

I hope I can go this year

winter linden
winter linden
last pine
#

nothing posted yet

fossil pine
mystic mantle
turbid tulip
fossil pine
#

Awesome!

Thanks for the link!

real kite
#

Is it expected behavior for client.directory() to return anything other than an empty directory? Docs say that it should return an empty directory if no id is supplied, but when I call it in my code I get the directory contents from a previous run. Is that expected behavior?

carmine sandal
#

the new dagger engine container doesn't work with docker compose?

#

the container can't access my other services in host

winter linden
carmine sandal
#

does Dagger works with remote buildkit?

sharp marsh
lusty void
#

Hi, I'm really like dagger's idea of implementing the whole pipeline as code. Correct me if I'm wrong, currently dagger is limited to single machine execution. Meaning that the whole pipeline will always run in the same machine. Is there any plan to integrate dagger with orchestration platform like k8s? I'm thinking of more like an workflow engine like tekton/argo workflows but as code

swift inlet
# lusty void Hi, I'm really like dagger's idea of implementing the whole pipeline as code. C...

Hi @lusty void ,
You're right regarding the current state of Dagger ๐Ÿ˜‡
Regarding the second part of your question, it is something under discussion / design. The idea is indeed to be able, at some point, to cluster the engines together. As it is something quite tricky, the first step, on our side, is to enable the use of custom provisioned engine image, more context on this issue https://github.com/dagger/dagger/issues/4105

rain quiver
#

Hi,
I discover Dagger and found it very interesting, I'm currently in my last year of DevOps Engineering and I'm searching for an Internship to validate my diploma. I was wondering if youโ€™d have any opportunity at Dagger.
PS: I hope the place isnโ€™t inappropriate for this question

candid wave
#

im kinda missing docs on how one would integrate dagger with forges like gitea, gitlab or github to run ones pipelines against prs /eventsof a repo - is there any quickstart for that?

candid wave
swift inlet
# candid wave im kinda missing docs on how one would integrate dagger with forges like gitea, ...

Hi @candid wave,
Here is the available docs on how to integrate Dagger on most forges: https://docs.dagger.io/768421/go-ci/. It can be easily tweaked to all SDKs.

If some are missing, we're really open to contributions ๐Ÿ˜‡ Regarding the native dagger integration, we currently don't have "apps" available to integrate Dagger on the pipelines. However, it's under discussion. We used to have a Github Apps, but it hasn't been updated to fit with latest Dagger engine.

There's just one thing I am not sure to understand: to run ones pipelines against prs /eventsof a repo. Currently, the context on which a Dagger pipeline runs lies inside the forges (to run a pipeline against a PR, specify that in your workflow). Does it answer your questions ๐Ÿ˜‡

swift inlet
candid wave
swift inlet
# candid wave this practically means that dagger is not a standalone system, its always a "pig...

I understand your point of view ๐Ÿ˜‡. As we you can use Dagger with code, there's no limit per-se, you could totally code that internal logic in your preferred language. By the way, the cache management of Dagger might help you implementing it.

The truth is that we had experiments to do exactly that. However, the investment was getting too big for the stage of the company.

Considering that most of forges nowadays include a ci system (Github Action, Gitlab ...), or that most of the users here alternatively rely on a CI system, it seems to be an acceptable tradeoff. Especially because most of CI systems accept containers, and integrate perfectly with Dagger.

Even though it would be nice to have that in Dagger, you're 100% right, we first prioritize the stabilization of the engine, and we believe that the fastest way to solve the run your pipeline locally and easily need is to focus on the engine for now. We hope that our solution is such a better developer experience that users (and you) would be ok to rely on a CI system as a tradeoff ๐Ÿ˜‡

PS: nothing is set in stone + it's a personal opinion ๐Ÿ‘ผ

candid wave
swift inlet
candid wave
thorn axle
#

Just got the go ahead from upper management to automate our aws lambda deployments with dagger! We currently don't have any CI/CD in place for our deployments, so this will be interesting. I will be using CircleCI to run the dagger pipelines in our hosted runner. Super excited to deep dive into dagger and will post any interesting finds I come across

swift inlet
winter linden
#

AWS lambda deployment

rough wind
#

Is it possible to run health check on a MySQL DB with the graphql API?

winter linden
# rough wind Is it possible to run health check on a MySQL DB with the graphql API?

If you mean a mysql DB running externally to Dagger, then yes you can orchestrate running a mysql client in a container(or raw tcp port checker depending on the kind of health checklist logic you want).

If you mean for a mysql db run by dagger, that will require the services API , coming soon, and container networking which is also in development and includes a proposal for builtin TCP port checks. See https://github.com/dagger/dagger/issues/4080

GitHub

Overview This issue tracks the design and implementation status of container networking, in its various forms. Host-to-container (h2c) Container-to-host (c2h) Container-to-container (c2c) Use cases...

rough wind
#

Cool, I'll wait my use case requires spinning up MySQL and another cli and let them communicate

winter linden
#

@rough wind would you mind adding a comment to that container networking issue, to mention that your use case requires it? It helps us prioritize, and keep you informed of our progress. Even a few words is fine.

rough wind
#

Done!

rigid epoch
#

I just had a kind of wild idea: how practical would it be for Dagger to upload cache in parallel with the execution of other steps? Maybe this is more of a buildkit question...

The reason I'm asking is because I was just pondering the idea of using spot instances for my integration tests. Because they're already chunked out into convenient units of work and highly parallel, they should be easy to preempt. And then it occurred to me that buildkit execution steps have this same property -- at least, if their cache has been saved.

#

This probably isn't suitable for all workloads, but just thinking about how much of ci is running on eg in development feature branches, I think there's a lot of cases where 5% interruption chance would be worth huge savings on compute. And that's something dagger could facilitate, on top of what it already does for caching.

raw juniper
#

Hi Every one, so i already have a react project which i wanto start using dagger with typescript/nodejs however if i change my project to type module it breaks.

last pine
raw juniper
# last pine Hey <@689537037472104458> ๐Ÿ‘‹ What happens exactly ?

This is with type=module :
(node:52313) ExperimentalWarning: Custom ESM Loaders is an experimental feature. This feature could change at any time
(Use node --trace-warnings ... to show where the warning was created)
ReferenceError: exports is not defined in ES module scope
at file:///Users/mahmoudnashef/Work/workcanvas/build.ts:2:23
at ModuleJob.run (node:internal/modules/esm/module_job:193:25)
at async Promise.all (index 0)
at async ESMLoader.import (node:internal/modules/esm/loader:541:24)
at async loadESM (node:internal/process/esm_loader:91:5)
at async handleMainPromise (node:internal/modules/run_main:65:12)

raw juniper
# last pine Hey <@689537037472104458> ๐Ÿ‘‹ What happens exactly ?

but type module breaks my app. so this is without type module:

(node:52554) ExperimentalWarning: Custom ESM Loaders is an experimental feature. This feature could change at any time
(Use node --trace-warnings ... to show where the warning was created)
/Users/mahmoudnashef/Work/workcanvas/node_modules/ts-node/dist/index.js:851
return old(m, filename);
^
Error [ERR_REQUIRE_ESM]: require() of ES Module /Users/mahmoudnashef/Work/workcanvas/node_modules/@dagger.io/dagger/dist/index.js from /Users/mahmoudnashef/Work/workcanvas/build.ts not supported.
Instead change the require of index.js in /Users/mahmoudnashef/Work/workcanvas/build.ts to a dynamic import() which is available in all CommonJS modules.
at require.extensions.<computed> [as .js] (/Users/mahmoudnashef/Work/workcanvas/node_modules/ts-node/dist/index.js:851:20)
at Object.<anonymous> (/Users/mahmoudnashef/Work/workcanvas/build.ts:3:18)
at m._compile (/Users/mahmoudnashef/Work/workcanvas/node_modules/ts-node/dist/index.js:857:29)
at require.extensions.<computed> [as .ts] (/Users/mahmoudnashef/Work/workcanvas/node_modules/ts-node/dist/index.js:859:16)
at async Promise.all (index 0) {
code: 'ERR_REQUIRE_ESM'

last pine
raw juniper
sharp marsh
# rigid epoch I just had a kind of wild idea: how practical would it be for Dagger to upload c...

hey David, good idea. I'm not sure if buildkit allows exporting the cache while executing other steps. IIUC exporting the buildkit cache is generally the last step after the build has finished using buildctl. Having said that, by using the buildkit API directly there might be a way to achieve what you're thinking which I also believe it's very valuable.

i.e:

c.Container().
From("maven").
WithExec([]string{"mvn", "install"}).
Export(). // find the way to do this async while starting the next exec?
WithExec([]string{"mvn", "package"}).
ExitCode()

^ is something like this what you had in mind?

cc @pseudo stream @elfin frigate

rigid epoch
sharp marsh
rigid epoch
#

I'd think that's a great example of something you'd want to cache, actually -- if the layers leading up to the build turn out to be the same, you'd want to be able to skip the build

#

In a monorepo that sort of thing happens a lot (in my experience)

sharp marsh
# rigid epoch I'd think that's a great example of something you'd want to cache, actually -- i...

well.. it really depends. Imagine the usual common scenario of:

  • Pull base image
  • Add go.mod and go.sum
  • Pull dependencies
  • Add source code
  • Build application

Generally you wouldn't want to cache the "add source code" and "build application" steps since those are the ones that usually change and you need to re-run. Having said that, dagger/buildkit already caches everything automatically as long as you're running the pipelines using the same buildkit underlying volume. I am assuming that in your case you're referring to export/import cache since you want that to be ephemeral across spot instace runs

rigid epoch
#

I am thinking about export and import, yeah (although obviously a volume is better if you have one). And that makes sense about the copy steps, I'm so used to thinking of cache as an all other nothing proposition (just set inline cache to true and forget about it)

winter linden
#

@rigid epoch may I suggest an issue for continuity? ๐Ÿ™‚

rigid epoch
winter linden
rigid epoch
real kite
#

For environment variables on the host, I noticed that if you do this:

 initialize the dagger client -> do something to load some new environment variables onto the host -> attempt to call client.host().env_variable("MY_NEWLY_LOADED_ENV_VAR")

it won't find the environment variable. The env var appears to have to exist before the client is initialized. This is in the Python SDK

  1. Is this expected behavior?
  2. If 1, is loading environment variables onto the host after client is initialized unsupported?

You can reproduce with this simple slice of code:


import os
import sys
import anyio
import dagger

async def run_workflow():

    config = dagger.Config(log_output=sys.stderr, execute_timeout=3000)
    os.environ["MY_VAR"] = "test"
    async with dagger.Connection(config) as client: 
        # os.environ["MY_VAR"] = "test"
        my_var = await client.host().env_variable("MY_VAR").value()
        my_container = (
            client.container()
            .from_("alpine")
            .with_env_variable("MY_VAR_INSIDE_CONTAINER", my_var)
            .exec(["/bin/sh", "-c", "echo $MY_VAR_INSIDE_CONTAINER >> /var.txt"])
            .file("/var.txt")
            .export("/tmp/var.txt")
        )
        await my_container
        with open('/tmp/var.txt', 'r') as f:
            print(f.read())



if __name__ == "__main__":
    anyio.run(run_workflow)

The above prints test as expected.

But if you comment out the first os.environ["MY_VAR"] = "test" and uncomment the second, it prints nothing

rigid epoch
tender stump
woven tide
tender stump
#

i tried but the final outcome of the command comes at the end

#

for now I'm using core.#Nop (because // using #Nop because we need an action for the outputs ) but I'm not sure if its the right approach

sharp marsh