Skip to content

Commit

Permalink
Add environment variables for issue editor
Browse files Browse the repository at this point in the history
Signed-off-by: Jeny Sadadia <[email protected]>
  • Loading branch information
Jeny Sadadia committed Sep 27, 2024
1 parent f721cf0 commit b3d84f4
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
7 changes: 5 additions & 2 deletions cloud
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ function execute_command() {
declare -r cache_bucket_name="${project}_${prefix}cache"
declare -r pick_notifications_trigger_topic="${prefix}pick_notifications_trigger"
declare -r purge_db_trigger_topic="${prefix}purge_db_trigger"
declare -r topic="playground_kcidb_new"
declare -r cache_redirect_function_name="cache_redirect"
declare cache_redirector_url="https://${FUNCTION_REGION}"
declare cache_redirector_url+="-${project}.cloudfunctions.net/"
Expand Down Expand Up @@ -380,7 +381,8 @@ function execute_command() {
--cost-mon-image="$cost_mon_image" \
--cost-upd-service-account="$cost_upd_service_account" \
--iss-ed-service="$iss_ed_service" \
--iss-ed-image="$iss_ed_image"
--iss-ed-image="$iss_ed_image" \
--topic="$topic"
sections_run "$sections" pubsub_deploy \
--project="$project" \
--load-queue-trigger-topic="$load_queue_trigger_topic" \
Expand Down Expand Up @@ -414,7 +416,8 @@ function execute_command() {
--updated-topic="$updated_topic" \
--cache-redirect-function-name="$cache_redirect_function_name" \
--spool-collection-path="$spool_collection_path" \
--env-yaml="${env_yaml}"
--env-yaml="${env_yaml}" \
--topic="$topic"
sections_run "$sections" scheduler_deploy \
--project="$project" \
--prefix="$prefix" \
Expand Down
4 changes: 4 additions & 0 deletions kcidb/cloud/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ function run_service_withdraw() {
# --cost-upd-service-account=EMAIL
# --iss-ed-service=NAME
# --iss-ed-image=URL
# --topic=STRING
function run_deploy() {
declare params
params="$(getopt_vars project \
Expand All @@ -104,6 +105,7 @@ function run_deploy() {
cost_upd_service_account \
iss_ed_service \
iss_ed_image \
topic \
-- "$@")"
eval "$params"
declare iam_command
Expand Down Expand Up @@ -263,6 +265,8 @@ YAML_END
limits:
cpu: "0.25"
memory: "256M"
args:
- $(yaml_quote "$topic")
YAML_END
}

Expand Down
2 changes: 2 additions & 0 deletions kcidb/issue_editor/kcidb_triage_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ def read_server_config():
origin = config.get("submission", "origin")

client = kcidb.Client(project_id=project_id, topic_name=topic_name)
print("project name:", os.environ.get("project"))
print("topic name:", os.environ.get("topic"))


@app.route('/')
Expand Down

0 comments on commit b3d84f4

Please sign in to comment.