CouchDB
  1. CouchDB
  2. COUCHDB-472

handle custom CouchdDB welcome page

    Details

    • Type: Improvement Improvement
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 0.10
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Skill Level:
      New Contributors Level (Easy)

      Description

      This change modify behaviour of Welcome handler by allowing admin to customize the welcome page. If content is "application/json" it will send current json object, if not, it will send an html page or redirect to another path.

      This patch change the confugration string to a tupple

      {WelcomeMsg, WelcomePage}

      . WelcomePage could be a string for DocumentRoot where it will find welcome.html page or a tupple

      {redirect, Url}

      Ex if in config you have:
      / = {couch_httpd_misc_handlers, handle_welcome_req, {<<"Welcome">>, "/usr/local/share/couchdb/www"}}

      If Accept content is application/json Couchdb will send :
      "couchdb":"Welcome","version":"0.10.0a"}

      If other it will send welcome.html.

      if you replace "/usr/local/share/couchdb/www" by

      {redirect, <<"/_utils">>}

       user will be redirected on futon.

      1. COUCHDB-472-2.patch
        6 kB
        Benoit Chesneau
      2. Welcome page screenshot.jpg
        64 kB
        Benoit Chesneau
      3. COUCHDB-472.patch
        6 kB
        Benoit Chesneau
      4. couchdb_welcome3.patch
        4 kB
        Benoit Chesneau
      5. couchdb_welcome2.patch
        9 kB
        Benoit Chesneau
      6. screenshot.png
        118 kB
        Benoit Chesneau
      7. couchdb_welcome.patch
        5 kB
        Benoit Chesneau

        Issue Links

          Activity

          No work has yet been logged on this issue.

            People

            • Assignee:
              Benoit Chesneau
              Reporter:
              Benoit Chesneau
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Development