package dbt
import (
"dagger.io/dagger"
"universe.dagger.io/bash" // import this package to execute bash commands inside a docker container
"universe.dagger.io/docker" // import this package to set up docker
)
dagger.#Plan & {
// configure the client so that dagger takes only the files it needs
client: filesystem: "./": read: {
contents: dagger.#FS
exclude: [
"README.md",
"ci.cue",
"Vagrantfile",
"target/",
".vagrant/",
]
}
actions: {
// copy contents of repo
deps: docker.#Build & {
steps: [
docker.#Pull & {
source: "python:3.9.11"
},
docker.#Copy & {
contents: client.filesystem."./".read.contents
dest: "/app"
},
]
}
// print python version
version: bash.#Run & {
input: deps.output
workdir: "/app"
script: contents: #"""
echo python --version
"""#
}
}
}
I would like to see the Python version printed to the terminal.