|
|
@ -53,5 +53,12 @@ def build_image(c, dev=True, registry_user=None, registry_token=None, push=False
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@task
|
|
|
|
@task
|
|
|
|
def serve_dev(c):
|
|
|
|
def serve_dev(c, otel=False):
|
|
|
|
c.run("FLASK_APP=./learn_otel/app.py flask run -p 8888")
|
|
|
|
if otel:
|
|
|
|
|
|
|
|
c.run(
|
|
|
|
|
|
|
|
"FLASK_APP=./learn_otel/app.py OTEL_PYTHON_LOGGING_AUTO_INSTRUMENTATION_ENABLED=true "
|
|
|
|
|
|
|
|
"opentelemetry-instrument --traces_exporter console --metrics_exporter console --logs_exporter console "
|
|
|
|
|
|
|
|
"--service_name dice-server flask run -p 8888"
|
|
|
|
|
|
|
|
)
|
|
|
|
|
|
|
|
else:
|
|
|
|
|
|
|
|
c.run("FLASK_APP=./learn_otel/app.py flask run -p 8888")
|
|
|
|