prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Local installation requires filled-out GCP section of config
  I'm attempting to get Turbinia working locally on a laptop. The laptop has internet for at least the installation part of this process.
  
  Running into an issue with the config. I set the TASK_MANAGER to use Celery, but the installation process is still requiring me to have values for:
  
  - TURBINIA_PROJECT
  - TURBINIA_ZONE
  - TURBINIA_REGION
  - BUCKET_NAME
  
  According to the instructions in the config, these values should only matter if the TASK_MANAGER is set to PSQ.
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `turbinia/config/turbinia_config.py`
  Content:
  ```
  1 # -*- coding: utf-8 -*-
  2 # Copyright 2016 Google Inc.
  3 #
  4 # Licensed under the Apache License, Version 2.0 (the "License");
  5 # you may not use this file except in compliance with the License.
  6 # You may obtain a copy of the License at
  7 #
  8 #      http://www.apache.org/licenses/LICENSE-2.0
  9 #
  10 # Unless required by applicable law or agreed to in writing, software
  11 # distributed under the License is distributed on an "AS IS" BASIS,
  12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13 # See the License for the specific language governing permissions and
  14 # limitations under the License.
  15 """Turbinia Config Template"""
  16 
  17 from __future__ import unicode_literals
  18 
  19 ################################################################################
  20 #                          Base Turbinia configuration
  21 #
  22 # All options in this section are required to be set to non-empty values.
  23 ################################################################################
  24 
  25 # A unique ID per Turbinia instance. Used to keep multiple Turbinia instances
  26 # separate when running with the same Cloud projects or backend servers.
  27 INSTANCE_ID = 'turbinia-instance1'
  28 
  29 # Which state manager to use. Valid options are 'Datastore' or 'Redis'.
  30 STATE_MANAGER = 'Datastore'
  31 
  32 # Which Task manager to use. Valid options are 'PSQ' and 'Celery'.
  33 TASK_MANAGER = 'PSQ'
  34 
  35 # Default base output directory for worker results and evidence.
  36 OUTPUT_DIR = '/var/tmp'
  37 
  38 # Directory for temporary files.  Some temporary files can be quite large (e.g.
  39 # Plaso files can easily be multiple gigabytes), so make sure there is enough
  40 # space.  Nothing from this directory will be saved.  This directory should be
  41 # different from the OUTPUT_DIR.
  42 TMP_DIR = '/tmp'
  43 
  44 # File to log debugging output to.
  45 LOG_FILE = '%s/turbinia.log' % OUTPUT_DIR
  46 
  47 # Path to a lock file used for the worker tasks.
  48 LOCK_FILE = '%s/turbinia-worker.lock' % OUTPUT_DIR
  49 
  50 # Time in seconds to sleep in task management loops
  51 SLEEP_TIME = 10
  52 
  53 # Whether to run as a single run, or to keep server running indefinitely
  54 SINGLE_RUN = False
  55 
  56 # Local directory in the worker to put other mount directories for locally
  57 # mounting images/disks
  58 MOUNT_DIR_PREFIX = '/mnt/turbinia-mounts'
  59 
  60 # This indicates whether the workers are running in an environment with a shared
  61 # filesystem.  This should be False for environments with workers running in
  62 # GCE, and True for environments that have workers on dedicated machines with
  63 # NFS or a SAN for storing Evidence objects.
  64 SHARED_FILESYSTEM = False
  65 
  66 # This will set debugging flags for processes executed by Tasks (for
  67 # Tasks/binaries that support it).  This could cause performance issues with
  68 # some tasks, so it is recommended to only set this to True when debugging
  69 # problems.
  70 DEBUG_TASKS = False
  71 
  72 ################################################################################
  73 #                        Google Cloud Platform (GCP)
  74 #
  75 # Options in this section are required if the TASK_MANAGER is set to 'PSQ'.
  76 ################################################################################
  77 
  78 # GCP project, region and zone where Turbinia will run.  Note that Turbinia does
  79 # not currently support multi-zone operation.  Even if you are running Turbinia
  80 # in Hybrid mode (with the Server and Workers running on local machines), you
  81 # will still need to provide these three parameters.
  82 TURBINIA_PROJECT = None
  83 TURBINIA_ZONE = None
  84 TURBINIA_REGION = None
  85 
  86 # GCS bucket that has Turbinia specific scripts and can be used to store logs.
  87 # This must be globally unique within GCP.
  88 BUCKET_NAME = None
  89 
  90 # This is the internal PubSub topic that PSQ will use.  This should be different
  91 # than the PUBSUB_TOPIC variable.  The actual PubSub topic created will be this
  92 # variable prefixed with 'psq-'.
  93 PSQ_TOPIC = 'turbinia-psq'
  94 
  95 # The PubSub topic Turbinia will listen on for new requests.  This should be
  96 # different than the PSQ_TOPIC variable.
  97 PUBSUB_TOPIC = INSTANCE_ID
  98 
  99 # GCS Path to copy worker results and Evidence output to.
  100 # Otherwise, set this as 'None' if output will be stored in shared storage.
  101 # GCS_OUTPUT_PATH = 'gs://%s/output' % BUCKET_NAME
  102 GCS_OUTPUT_PATH = None
  103 
  104 ################################################################################
  105 #                           Celery / Redis / Kombu
  106 #
  107 # Options in this section are required if TASK_MANAGER is set to 'Celery'
  108 ################################################################################
  109 
  110 # Method for communication between nodes
  111 CELERY_BROKER = 'redis://localhost'
  112 
  113 # Storage for task results/status
  114 CELERY_BACKEND = 'redis://localhost'
  115 
  116 # Can be the same as CELERY_BROKER
  117 KOMBU_BROKER = CELERY_BROKER
  118 
  119 # Used to namespace communications.
  120 KOMBU_CHANNEL = '%s-kombu' % INSTANCE_ID
  121 
  122 # Will messages be persistent and require acknowledgment?
  123 # http://docs.celeryproject.org/projects/kombu/en/4.0/reference/kombu.html#kombu.Connection.SimpleBuffer
  124 KOMBU_DURABLE = True
  125 
  126 # Use Redis for state management
  127 REDIS_HOST = 'localhost'
  128 REDIS_PORT = '6379'
  129 REDIS_DB = '0'
  130
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/turbinia/config/turbinia_config.py b/turbinia/config/turbinia_config.py
  --- a/turbinia/config/turbinia_config.py
  +++ b/turbinia/config/turbinia_config.py
  @@ -26,10 +26,14 @@
   # separate when running with the same Cloud projects or backend servers.
   INSTANCE_ID = 'turbinia-instance1'
   
  -# Which state manager to use. Valid options are 'Datastore' or 'Redis'.
  +# Which state manager to use. Valid options are 'Datastore' or 'Redis'.  Use
  +# 'Datastore' for Cloud (GCP) or hybrid installations, and 'Redis' for local
  +# installations.
   STATE_MANAGER = 'Datastore'
   
  -# Which Task manager to use. Valid options are 'PSQ' and 'Celery'.
  +# Which Task manager to use. Valid options are 'PSQ' and 'Celery'.  Use 'PSQ'
  +# for Cloud (GCP) or hybrid installations, and 'Celery' for local
  +# installations.
   TASK_MANAGER = 'PSQ'
   
   # Default base output directory for worker results and evidence.
  
verification_info: {"golden_diff": "diff --git a/turbinia/config/turbinia_config.py b/turbinia/config/turbinia_config.py\n--- a/turbinia/config/turbinia_config.py\n+++ b/turbinia/config/turbinia_config.py\n@@ -26,10 +26,14 @@\n # separate when running with the same Cloud projects or backend servers.\n INSTANCE_ID = 'turbinia-instance1'\n \n-# Which state manager to use. Valid options are 'Datastore' or 'Redis'.\n+# Which state manager to use. Valid options are 'Datastore' or 'Redis'.  Use\n+# 'Datastore' for Cloud (GCP) or hybrid installations, and 'Redis' for local\n+# installations.\n STATE_MANAGER = 'Datastore'\n \n-# Which Task manager to use. Valid options are 'PSQ' and 'Celery'.\n+# Which Task manager to use. Valid options are 'PSQ' and 'Celery'.  Use 'PSQ'\n+# for Cloud (GCP) or hybrid installations, and 'Celery' for local\n+# installations.\n TASK_MANAGER = 'PSQ'\n \n # Default base output directory for worker results and evidence.\n", "issue": "Local installation requires filled-out GCP section of config\nI'm attempting to get Turbinia working locally on a laptop. The laptop has internet for at least the installation part of this process.\r\n\r\nRunning into an issue with the config. I set the TASK_MANAGER to use Celery, but the installation process is still requiring me to have values for:\r\n\r\n- TURBINIA_PROJECT\r\n- TURBINIA_ZONE\r\n- TURBINIA_REGION\r\n- BUCKET_NAME\r\n\r\nAccording to the instructions in the config, these values should only matter if the TASK_MANAGER is set to PSQ.\n", "before_files": [{"content": "# -*- coding: utf-8 -*-\n# Copyright 2016 Google Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#      http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\"\"\"Turbinia Config Template\"\"\"\n\nfrom __future__ import unicode_literals\n\n################################################################################\n#                          Base Turbinia configuration\n#\n# All options in this section are required to be set to non-empty values.\n################################################################################\n\n# A unique ID per Turbinia instance. Used to keep multiple Turbinia instances\n# separate when running with the same Cloud projects or backend servers.\nINSTANCE_ID = 'turbinia-instance1'\n\n# Which state manager to use. Valid options are 'Datastore' or 'Redis'.\nSTATE_MANAGER = 'Datastore'\n\n# Which Task manager to use. Valid options are 'PSQ' and 'Celery'.\nTASK_MANAGER = 'PSQ'\n\n# Default base output directory for worker results and evidence.\nOUTPUT_DIR = '/var/tmp'\n\n# Directory for temporary files.  Some temporary files can be quite large (e.g.\n# Plaso files can easily be multiple gigabytes), so make sure there is enough\n# space.  Nothing from this directory will be saved.  This directory should be\n# different from the OUTPUT_DIR.\nTMP_DIR = '/tmp'\n\n# File to log debugging output to.\nLOG_FILE = '%s/turbinia.log' % OUTPUT_DIR\n\n# Path to a lock file used for the worker tasks.\nLOCK_FILE = '%s/turbinia-worker.lock' % OUTPUT_DIR\n\n# Time in seconds to sleep in task management loops\nSLEEP_TIME = 10\n\n# Whether to run as a single run, or to keep server running indefinitely\nSINGLE_RUN = False\n\n# Local directory in the worker to put other mount directories for locally\n# mounting images/disks\nMOUNT_DIR_PREFIX = '/mnt/turbinia-mounts'\n\n# This indicates whether the workers are running in an environment with a shared\n# filesystem.  This should be False for environments with workers running in\n# GCE, and True for environments that have workers on dedicated machines with\n# NFS or a SAN for storing Evidence objects.\nSHARED_FILESYSTEM = False\n\n# This will set debugging flags for processes executed by Tasks (for\n# Tasks/binaries that support it).  This could cause performance issues with\n# some tasks, so it is recommended to only set this to True when debugging\n# problems.\nDEBUG_TASKS = False\n\n################################################################################\n#                        Google Cloud Platform (GCP)\n#\n# Options in this section are required if the TASK_MANAGER is set to 'PSQ'.\n################################################################################\n\n# GCP project, region and zone where Turbinia will run.  Note that Turbinia does\n# not currently support multi-zone operation.  Even if you are running Turbinia\n# in Hybrid mode (with the Server and Workers running on local machines), you\n# will still need to provide these three parameters.\nTURBINIA_PROJECT = None\nTURBINIA_ZONE = None\nTURBINIA_REGION = None\n\n# GCS bucket that has Turbinia specific scripts and can be used to store logs.\n# This must be globally unique within GCP.\nBUCKET_NAME = None\n\n# This is the internal PubSub topic that PSQ will use.  This should be different\n# than the PUBSUB_TOPIC variable.  The actual PubSub topic created will be this\n# variable prefixed with 'psq-'.\nPSQ_TOPIC = 'turbinia-psq'\n\n# The PubSub topic Turbinia will listen on for new requests.  This should be\n# different than the PSQ_TOPIC variable.\nPUBSUB_TOPIC = INSTANCE_ID\n\n# GCS Path to copy worker results and Evidence output to.\n# Otherwise, set this as 'None' if output will be stored in shared storage.\n# GCS_OUTPUT_PATH = 'gs://%s/output' % BUCKET_NAME\nGCS_OUTPUT_PATH = None\n\n################################################################################\n#                           Celery / Redis / Kombu\n#\n# Options in this section are required if TASK_MANAGER is set to 'Celery'\n################################################################################\n\n# Method for communication between nodes\nCELERY_BROKER = 'redis://localhost'\n\n# Storage for task results/status\nCELERY_BACKEND = 'redis://localhost'\n\n# Can be the same as CELERY_BROKER\nKOMBU_BROKER = CELERY_BROKER\n\n# Used to namespace communications.\nKOMBU_CHANNEL = '%s-kombu' % INSTANCE_ID\n\n# Will messages be persistent and require acknowledgment?\n# http://docs.celeryproject.org/projects/kombu/en/4.0/reference/kombu.html#kombu.Connection.SimpleBuffer\nKOMBU_DURABLE = True\n\n# Use Redis for state management\nREDIS_HOST = 'localhost'\nREDIS_PORT = '6379'\nREDIS_DB = '0'\n", "path": "turbinia/config/turbinia_config.py"}], "after_files": [{"content": "# -*- coding: utf-8 -*-\n# Copyright 2016 Google Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#      http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\"\"\"Turbinia Config Template\"\"\"\n\nfrom __future__ import unicode_literals\n\n################################################################################\n#                          Base Turbinia configuration\n#\n# All options in this section are required to be set to non-empty values.\n################################################################################\n\n# A unique ID per Turbinia instance. Used to keep multiple Turbinia instances\n# separate when running with the same Cloud projects or backend servers.\nINSTANCE_ID = 'turbinia-instance1'\n\n# Which state manager to use. Valid options are 'Datastore' or 'Redis'.  Use\n# 'Datastore' for Cloud (GCP) or hybrid installations, and 'Redis' for local\n# installations.\nSTATE_MANAGER = 'Datastore'\n\n# Which Task manager to use. Valid options are 'PSQ' and 'Celery'.  Use 'PSQ'\n# for Cloud (GCP) or hybrid installations, and 'Celery' for local\n# installations.\nTASK_MANAGER = 'PSQ'\n\n# Default base output directory for worker results and evidence.\nOUTPUT_DIR = '/var/tmp'\n\n# Directory for temporary files.  Some temporary files can be quite large (e.g.\n# Plaso files can easily be multiple gigabytes), so make sure there is enough\n# space.  Nothing from this directory will be saved.  This directory should be\n# different from the OUTPUT_DIR.\nTMP_DIR = '/tmp'\n\n# File to log debugging output to.\nLOG_FILE = '%s/turbinia.log' % OUTPUT_DIR\n\n# Path to a lock file used for the worker tasks.\nLOCK_FILE = '%s/turbinia-worker.lock' % OUTPUT_DIR\n\n# Time in seconds to sleep in task management loops\nSLEEP_TIME = 10\n\n# Whether to run as a single run, or to keep server running indefinitely\nSINGLE_RUN = False\n\n# Local directory in the worker to put other mount directories for locally\n# mounting images/disks\nMOUNT_DIR_PREFIX = '/mnt/turbinia-mounts'\n\n# This indicates whether the workers are running in an environment with a shared\n# filesystem.  This should be False for environments with workers running in\n# GCE, and True for environments that have workers on dedicated machines with\n# NFS or a SAN for storing Evidence objects.\nSHARED_FILESYSTEM = False\n\n# This will set debugging flags for processes executed by Tasks (for\n# Tasks/binaries that support it).  This could cause performance issues with\n# some tasks, so it is recommended to only set this to True when debugging\n# problems.\nDEBUG_TASKS = False\n\n################################################################################\n#                        Google Cloud Platform (GCP)\n#\n# Options in this section are required if the TASK_MANAGER is set to 'PSQ'.\n################################################################################\n\n# GCP project, region and zone where Turbinia will run.  Note that Turbinia does\n# not currently support multi-zone operation.  Even if you are running Turbinia\n# in Hybrid mode (with the Server and Workers running on local machines), you\n# will still need to provide these three parameters.\nTURBINIA_PROJECT = None\nTURBINIA_ZONE = None\nTURBINIA_REGION = None\n\n# GCS bucket that has Turbinia specific scripts and can be used to store logs.\n# This must be globally unique within GCP.\nBUCKET_NAME = None\n\n# This is the internal PubSub topic that PSQ will use.  This should be different\n# than the PUBSUB_TOPIC variable.  The actual PubSub topic created will be this\n# variable prefixed with 'psq-'.\nPSQ_TOPIC = 'turbinia-psq'\n\n# The PubSub topic Turbinia will listen on for new requests.  This should be\n# different than the PSQ_TOPIC variable.\nPUBSUB_TOPIC = INSTANCE_ID\n\n# GCS Path to copy worker results and Evidence output to.\n# Otherwise, set this as 'None' if output will be stored in shared storage.\n# GCS_OUTPUT_PATH = 'gs://%s/output' % BUCKET_NAME\nGCS_OUTPUT_PATH = None\n\n################################################################################\n#                           Celery / Redis / Kombu\n#\n# Options in this section are required if TASK_MANAGER is set to 'Celery'\n################################################################################\n\n# Method for communication between nodes\nCELERY_BROKER = 'redis://localhost'\n\n# Storage for task results/status\nCELERY_BACKEND = 'redis://localhost'\n\n# Can be the same as CELERY_BROKER\nKOMBU_BROKER = CELERY_BROKER\n\n# Used to namespace communications.\nKOMBU_CHANNEL = '%s-kombu' % INSTANCE_ID\n\n# Will messages be persistent and require acknowledgment?\n# http://docs.celeryproject.org/projects/kombu/en/4.0/reference/kombu.html#kombu.Connection.SimpleBuffer\nKOMBU_DURABLE = True\n\n# Use Redis for state management\nREDIS_HOST = 'localhost'\nREDIS_PORT = '6379'\nREDIS_DB = '0'\n", "path": "turbinia/config/turbinia_config.py"}]}