prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Increase attachment size limit
  Hello, 
  
  How can web change the max file limit of attachment in Roundcube ?
  
  Version 1.5
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `webmails/rainloop/start.py`
  Content:
  ```
  1 #!/usr/bin/python3
  2 
  3 import jinja2
  4 import os
  5 import shutil
  6 
  7 convert = lambda src, dst: open(dst, "w").write(jinja2.Template(open(src).read()).render(**os.environ))
  8 
  9 # Actual startup script
  10 os.environ["FRONT_ADDRESS"] = os.environ.get("FRONT_ADDRESS", "front")
  11 os.environ["IMAP_ADDRESS"] = os.environ.get("IMAP_ADDRESS", "imap")
  12 
  13 base = "/data/_data_/_default_/"
  14 shutil.rmtree(base + "domains/", ignore_errors=True)
  15 os.makedirs(base + "domains", exist_ok=True)
  16 os.makedirs(base + "configs", exist_ok=True)
  17 
  18 convert("/default.ini", "/data/_data_/_default_/domains/default.ini")
  19 convert("/config.ini", "/data/_data_/_default_/configs/config.ini")
  20 
  21 os.system("chown -R www-data:www-data /data")
  22 
  23 os.execv("/usr/local/bin/apache2-foreground", ["apache2-foreground"])
  24 
  25
  ```
  
  Path: `webmails/roundcube/start.py`
  Content:
  ```
  1 #!/usr/bin/python3
  2 
  3 import os
  4 
  5 # Fix some permissions
  6 os.system("mkdir -p /data/gpg")
  7 os.system("chown -R www-data:www-data /data")
  8 
  9 # Run apache
  10 os.execv("/usr/local/bin/apache2-foreground", ["apache2-foreground"])
  ```
  --- 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/webmails/rainloop/start.py b/webmails/rainloop/start.py
  --- a/webmails/rainloop/start.py
  +++ b/webmails/rainloop/start.py
  @@ -10,6 +10,8 @@
   os.environ["FRONT_ADDRESS"] = os.environ.get("FRONT_ADDRESS", "front")
   os.environ["IMAP_ADDRESS"] = os.environ.get("IMAP_ADDRESS", "imap")
   
  +os.environ["MAX_FILESIZE"] = str(int(int(os.environ.get("MESSAGE_SIZE_LIMIT"))*0.66/1048576))
  +
   base = "/data/_data_/_default_/"
   shutil.rmtree(base + "domains/", ignore_errors=True)
   os.makedirs(base + "domains", exist_ok=True)
  @@ -17,6 +19,7 @@
   
   convert("/default.ini", "/data/_data_/_default_/domains/default.ini")
   convert("/config.ini", "/data/_data_/_default_/configs/config.ini")
  +convert("/php.ini", "/usr/local/etc/php/conf.d/rainloop.ini")
   
   os.system("chown -R www-data:www-data /data")
   
  diff --git a/webmails/roundcube/start.py b/webmails/roundcube/start.py
  --- a/webmails/roundcube/start.py
  +++ b/webmails/roundcube/start.py
  @@ -1,6 +1,13 @@
   #!/usr/bin/python3
   
   import os
  +import jinja2
  +
  +convert = lambda src, dst: open(dst, "w").write(jinja2.Template(open(src).read()).render(**os.environ))
  +
  +os.environ["MAX_FILESIZE"] = str(int(int(os.environ.get("MESSAGE_SIZE_LIMIT"))*0.66/1048576))
  +
  +convert("/php.ini", "/usr/local/etc/php/conf.d/roundcube.ini")
   
   # Fix some permissions
   os.system("mkdir -p /data/gpg")
  
verification_info: {"golden_diff": "diff --git a/webmails/rainloop/start.py b/webmails/rainloop/start.py\n--- a/webmails/rainloop/start.py\n+++ b/webmails/rainloop/start.py\n@@ -10,6 +10,8 @@\n os.environ[\"FRONT_ADDRESS\"] = os.environ.get(\"FRONT_ADDRESS\", \"front\")\n os.environ[\"IMAP_ADDRESS\"] = os.environ.get(\"IMAP_ADDRESS\", \"imap\")\n \n+os.environ[\"MAX_FILESIZE\"] = str(int(int(os.environ.get(\"MESSAGE_SIZE_LIMIT\"))*0.66/1048576))\n+\n base = \"/data/_data_/_default_/\"\n shutil.rmtree(base + \"domains/\", ignore_errors=True)\n os.makedirs(base + \"domains\", exist_ok=True)\n@@ -17,6 +19,7 @@\n \n convert(\"/default.ini\", \"/data/_data_/_default_/domains/default.ini\")\n convert(\"/config.ini\", \"/data/_data_/_default_/configs/config.ini\")\n+convert(\"/php.ini\", \"/usr/local/etc/php/conf.d/rainloop.ini\")\n \n os.system(\"chown -R www-data:www-data /data\")\n \ndiff --git a/webmails/roundcube/start.py b/webmails/roundcube/start.py\n--- a/webmails/roundcube/start.py\n+++ b/webmails/roundcube/start.py\n@@ -1,6 +1,13 @@\n #!/usr/bin/python3\n \n import os\n+import jinja2\n+\n+convert = lambda src, dst: open(dst, \"w\").write(jinja2.Template(open(src).read()).render(**os.environ))\n+\n+os.environ[\"MAX_FILESIZE\"] = str(int(int(os.environ.get(\"MESSAGE_SIZE_LIMIT\"))*0.66/1048576))\n+\n+convert(\"/php.ini\", \"/usr/local/etc/php/conf.d/roundcube.ini\")\n \n # Fix some permissions\n os.system(\"mkdir -p /data/gpg\")\n", "issue": "Increase attachment size limit\nHello, \r\n\r\nHow can web change the max file limit of attachment in Roundcube ?\r\n\r\nVersion 1.5\n", "before_files": [{"content": "#!/usr/bin/python3\n\nimport jinja2\nimport os\nimport shutil\n\nconvert = lambda src, dst: open(dst, \"w\").write(jinja2.Template(open(src).read()).render(**os.environ))\n\n# Actual startup script\nos.environ[\"FRONT_ADDRESS\"] = os.environ.get(\"FRONT_ADDRESS\", \"front\")\nos.environ[\"IMAP_ADDRESS\"] = os.environ.get(\"IMAP_ADDRESS\", \"imap\")\n\nbase = \"/data/_data_/_default_/\"\nshutil.rmtree(base + \"domains/\", ignore_errors=True)\nos.makedirs(base + \"domains\", exist_ok=True)\nos.makedirs(base + \"configs\", exist_ok=True)\n\nconvert(\"/default.ini\", \"/data/_data_/_default_/domains/default.ini\")\nconvert(\"/config.ini\", \"/data/_data_/_default_/configs/config.ini\")\n\nos.system(\"chown -R www-data:www-data /data\")\n\nos.execv(\"/usr/local/bin/apache2-foreground\", [\"apache2-foreground\"])\n\n", "path": "webmails/rainloop/start.py"}, {"content": "#!/usr/bin/python3\n\nimport os\n\n# Fix some permissions\nos.system(\"mkdir -p /data/gpg\")\nos.system(\"chown -R www-data:www-data /data\")\n\n# Run apache\nos.execv(\"/usr/local/bin/apache2-foreground\", [\"apache2-foreground\"])", "path": "webmails/roundcube/start.py"}], "after_files": [{"content": "#!/usr/bin/python3\n\nimport jinja2\nimport os\nimport shutil\n\nconvert = lambda src, dst: open(dst, \"w\").write(jinja2.Template(open(src).read()).render(**os.environ))\n\n# Actual startup script\nos.environ[\"FRONT_ADDRESS\"] = os.environ.get(\"FRONT_ADDRESS\", \"front\")\nos.environ[\"IMAP_ADDRESS\"] = os.environ.get(\"IMAP_ADDRESS\", \"imap\")\n\nos.environ[\"MAX_FILESIZE\"] = str(int(int(os.environ.get(\"MESSAGE_SIZE_LIMIT\"))*0.66/1048576))\n\nbase = \"/data/_data_/_default_/\"\nshutil.rmtree(base + \"domains/\", ignore_errors=True)\nos.makedirs(base + \"domains\", exist_ok=True)\nos.makedirs(base + \"configs\", exist_ok=True)\n\nconvert(\"/default.ini\", \"/data/_data_/_default_/domains/default.ini\")\nconvert(\"/config.ini\", \"/data/_data_/_default_/configs/config.ini\")\nconvert(\"/php.ini\", \"/usr/local/etc/php/conf.d/rainloop.ini\")\n\nos.system(\"chown -R www-data:www-data /data\")\n\nos.execv(\"/usr/local/bin/apache2-foreground\", [\"apache2-foreground\"])\n\n", "path": "webmails/rainloop/start.py"}, {"content": "#!/usr/bin/python3\n\nimport os\nimport jinja2\n\nconvert = lambda src, dst: open(dst, \"w\").write(jinja2.Template(open(src).read()).render(**os.environ))\n\nos.environ[\"MAX_FILESIZE\"] = str(int(int(os.environ.get(\"MESSAGE_SIZE_LIMIT\"))*0.66/1048576))\n\nconvert(\"/php.ini\", \"/usr/local/etc/php/conf.d/roundcube.ini\")\n\n# Fix some permissions\nos.system(\"mkdir -p /data/gpg\")\nos.system(\"chown -R www-data:www-data /data\")\n\n# Run apache\nos.execv(\"/usr/local/bin/apache2-foreground\", [\"apache2-foreground\"])", "path": "webmails/roundcube/start.py"}]}