Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/warmuuh/jemini
gemini protocol for jetty and spring
https://github.com/warmuuh/jemini
Last synced: about 1 month ago
JSON representation
gemini protocol for jetty and spring
- Host: GitHub
- URL: https://github.com/warmuuh/jemini
- Owner: warmuuh
- Created: 2021-03-24T14:14:43.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-04-23T10:01:46.000Z (over 3 years ago)
- Last Synced: 2024-08-03T17:09:44.122Z (4 months ago)
- Language: Java
- Size: 138 KB
- Stars: 4
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
- awesome-gemini - jemini - dual gemini/http server on top of jetty with spring-boot integration (Servers / Graphical)
README
# jemini
gemini protocol server on top of jetty.# Features
* integration with jetty & spring boot
* supports all the goodies of normal spring boot webapp
* implicit input handling with `@GmiInput` parameter annotation
* dual-protocol: can serve both `gemini://` and `https://` at the same time, translating gemtext to html
* auto-redirect http to https
* input handling in both `gemini://` and `https://`, transparent to application
* client certificates for both `gemini://` and `https://`
* session-logic based on client-certificates, both for `gemini://` and `https://`
* css-support for html-rendered gemtext# Getting Started
## generate certificate
```
keytool -genkey -alias -keyalg RSA -keypass -storepass -keystore keystore.jks
``````yaml
# application.yaml
gemini:
server:
key-password: storepassword
keystore-password: storepassword
keystore: file:keystore.jks
dualHttp: true
css-for-http: /classless-tiny.css
``````xml
com.github.warmuuh.jemini
jemini-spring-boot-starter
1.0-SNAPSHOT
org.springframework.boot
spring-boot-starter-freemarker
```
then you can use spring mvc as usual
```java
@Controller
public class HelloWorldController {@GetMapping("/test")
public String test() {
return "index";
}@GetMapping("/test1")
@ResponseBody
public String test1() {
return "Hello World. this is a dynamic page: " + Math.random();
}
}
```