From 3c10481279f291c7b5aeabee8594ab91d5f78d08 Mon Sep 17 00:00:00 2001 From: Gregory COCHON Date: Tue, 19 Dec 2017 10:43:43 +0100 Subject: [PATCH] Define the license and add readme. --- LICENSE | 21 ++++++++++++++++++ README.md | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 87 insertions(+) create mode 100644 LICENSE create mode 100644 README.md diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..d3e1b0b --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2017 TECH'advantage + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..d334939 --- /dev/null +++ b/README.md @@ -0,0 +1,66 @@ +# edc httpd + +edc httpd is an embedded httpd server to serve the edc documention in standalone java application. + +## Configuration + +### Define the path +In the `src/main/java/resources` folder, create the file: `webserver.yml`. +Define the `base`variable to define the path to the published documentation. + +```yaml +base: /local/edc-httpd/html +``` + +*Optional* + +It is possible to override the default port (8088). You have to create a `server.yml` file and define its content like this: + +```yaml +httpPort: 9000 +ip: 0.0.0.0 +enableHttp: true +``` + +Modify the `httpPort` to define the nw port value. + +### Add the dependency + +**Maven** + +Add the dependency in your `pom.xml` for maven + +```xml + + fr.techad.edc + httpd-java + 1.0.0 + +``` + +**Gradle** + +```groovy +compile group: 'fr.techad.edc', name: 'httpd-java', version: '1.0.0' +``` + +### Start the server + +To start the start, add + +```java +package fr.techad.edc.demo; + +import fr.techad.edc.httpd.EdcWebServer; + +public class Main { + public static void main(String[] args) { + EdcWebServer.run(); + /* ... */ + } +} +``` + +## License + +MIT [TECH'advantage](mailto:contact@tech-advantage.com) \ No newline at end of file