{"id":50869515,"url":"https://github.com/augmentedlogic/mollyb","last_synced_at":"2026-06-24T12:01:16.567Z","repository":{"id":363615395,"uuid":"1260391950","full_name":"augmentedlogic/mollyb","owner":"augmentedlogic","description":"a basic gemini protocol server","archived":false,"fork":false,"pushed_at":"2026-06-16T19:08:16.000Z","size":78,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-16T21:09:07.722Z","etag":null,"topics":["gemini-protocol","server","web"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/augmentedlogic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-06-05T12:52:59.000Z","updated_at":"2026-06-16T19:10:40.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/augmentedlogic/mollyb","commit_stats":null,"previous_names":["augmentedlogic/mollyb"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/augmentedlogic/mollyb","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/augmentedlogic%2Fmollyb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/augmentedlogic%2Fmollyb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/augmentedlogic%2Fmollyb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/augmentedlogic%2Fmollyb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/augmentedlogic","download_url":"https://codeload.github.com/augmentedlogic/mollyb/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/augmentedlogic%2Fmollyb/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34731256,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-24T02:00:07.484Z","response_time":106,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gemini-protocol","server","web"],"created_at":"2026-06-15T04:00:24.293Z","updated_at":"2026-06-24T12:01:16.558Z","avatar_url":"https://github.com/augmentedlogic.png","language":"Java","funding_links":[],"categories":["Servers"],"sub_categories":["Graphical"],"readme":"# mollyb\n\nmollyb is a standalone gemini protocol server and library written in java, without dependencies.\n\n## supported features\n\n* serves .gmi files\n\n* automatically looks for index.gmi in a directory\n\n* uses TLS (1.2 or 1.3)\n\n* allows to set a default \"not found\" page\n\n* serves media files of type image/jpeg, image/png and image/gif\n\n* serves feed/xml files\n\n* writes a basic access log (if so configured)\n\n* returns a custom \"File not found\" page (if set) if file or path does not exist\n\n* dynamic pages/input handling: embedded use only (no cgi support)\n\n## currently unsupported features\n\n* client certificates (Identities)\n\n## Setup\n\n\n### Building\n\nAssuming you have some recent JDK and maven installed:\n\n* clone the repository\n\n* inside the folder, run\n\n```\nmvn package\n```\n\n### TLS\n\nThe server does not directly work with pem files. To help you convert your fullchain.pem and privkey.pem into a .jks (java keystore) file,\nsee the certifcates.sh in the scripts/ folder.\n\n## As a standalone server\n\n### Configuration\n\n* Copy the config/config.ini-dist file to config/config.ini\n\n* Set the required parameters, such as the path to your webroot\n\n### Starting the server\n\n```\njava -jar target/mollyb-server.jar /path/to/your/config.ini\n```\n\n### Does it work?\n\nSort of, yes.\n\ngemini://molly.augmentedlogic.com\n\n\n## Using mollyb as a library to create dynamic services \n\n\nYou can get mollyb from maven central\n\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.augmentedlogic\u003c/groupId\u003e\n    \u003cartifactId\u003emollyb\u003c/artifactId\u003e\n    \u003cversion\u003e0.7.4\u003c/version\u003e\n\u003c/dependency\u003e\n\n### Setting up the embedded service\n\n```\nimport com.augmentedlogic.mollyb.*;\n\npublic class Main {\n\n    public static void main( String[] args ) {\n\n        MollybService ms = new MollybService(\"0.0.0.0\", 1965);\n        // if you want debug output\n        ms.setDebug(true);\n\n        ms.setWebroot(\"/path/to/your/webroot\");\n        ms.setKeystore(\"/path/to/your/keystore.jks\");\n        ms.setKeystorePassword(\"mysecret\");\n        ms.setKeyPassword(\"mysecret\");\n        // set a custom not found page\n        ms.setCustomNotFound(\"/path/to/your/not_found.gmi\");\n\n        // logging\n        ms.setAccessLog(\"/path/to/your/access.log\");\n\n        // add a path that will be handle dynamically\n        ms.addHandler(\"/dynamic\", new ExampleHandler());\n\n        try {\n            ms.start();\n        } catch(Exception e) {\n            System.out.println(e);\n        }\n    }\n\n}\n```\n\nNote that addHandler() accepts both exact as well as wildcards, e.g. :\n\n```\n\nms.addHandler(\"/dynamic\", new ExampleHandler());\n\nor \n\nms.addHandler(\"/projects/*\", new ExampleHandler());\n\n```\n\nNow you need a handler, as an example, a handler that will take an input:\n\n\n```\nimport com.augmentedlogic.mollyb.*;\n\n    public class ExampleHandler implements GeminiHandler\n    {\n\n      public Response handle(Request request, Response response)\n      {\n\n            if(request.getQuery() == null) {\n\n                response.log.debug(\"client is \" + request.getRemoteAddress());\n                response.setHeader(Response.INPUT_REQUIRED);\n\n            } else {\n\n                response.setHeader(Response.OK);\n                response.log.debug(\"data recieved: \" + request.getQuery());\n\n                response.addBody(\"# Hello World\");\n                response.addBody(\"This is a dynamic page\");\n                response.addBody(\"QUERY was:\" + request.getQuery());\n                response.addBody(\"FROM:\" + request.getRemoteAddress());\n            }\n            return response;\n      }\n\n    }\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faugmentedlogic%2Fmollyb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faugmentedlogic%2Fmollyb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faugmentedlogic%2Fmollyb/lists"}