Skip to content
This repository has been archived by the owner on Nov 20, 2023. It is now read-only.

Support dapr log level and config for local run #376

Merged
merged 1 commit into from
Apr 17, 2020

Conversation

rynowak
Copy link
Member

@rynowak rynowak commented Apr 17, 2020

Fixes #296

Adds conditional logic for passing these properties to daprd.

Corrects logic for dealing with config. Dapr's config annotation in k8s
refers to kubernetes resource by name, but that's not possible with
local run. In local run dapr will expect the -config parameter to be
a file on disk. So, this change adds logic to look for a file by naming
convention and pass that locally instead.

Additionally added the ability for an extension to output to the console

  • this is needed because we want to tell the user if their config file
    can't be found, and specifically where we looked. I made the decision to
    log a message and skip if the config file isn't present, because we
    don't have a way to make settings conditional based on environment yet -
    it makes sense that someone might need to have a config in production
    but not in local dev.

Fixes #296

Adds conditional logic for passing these properties to `daprd`.

Corrects logic for dealing with config. Dapr's config annotation in k8s
refers to kubernetes resource by name, but that's not possible with
local run. In local run `dapr` will expect the `-config` parameter to be
a file on disk. So, this change adds logic to look for a file by naming
convention and pass that locally instead.

Additionally added the ability for an extension to output to the console
- this is needed because we want to tell the user if their config file
can't be found, and specifically where we looked. I made the decision to
log a message and skip if the config file isn't present, because we
don't have a way to make settings conditional based on environment yet -
it makes sense that someone might need to have a config in production
but not in local dev.
@rynowak rynowak merged commit a612693 into master Apr 17, 2020
@rynowak rynowak deleted the rynowak/dapr-local-run branch April 17, 2020 23:10
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

How can I inject dapr.io/config: "tracing" using tye?
2 participants