Readme, docker.io-config, docker-compose.yml
This commit is contained in:
30
README.md
30
README.md
@@ -1,8 +1,6 @@
|
||||
# buerokalender Project
|
||||
# buerokalender
|
||||
|
||||
This project uses Quarkus, the Supersonic Subatomic Java Framework.
|
||||
|
||||
If you want to learn more about Quarkus, please visit its website: https://quarkus.io/ .
|
||||
Eine kleine Webapp um die Belegung eines Büroarbeitsplatzes ohne Kollision zu buchen.
|
||||
|
||||
## Running the application in dev mode
|
||||
|
||||
@@ -11,16 +9,13 @@ You can run your application in dev mode that enables live coding using:
|
||||
./mvnw compile quarkus:dev
|
||||
```
|
||||
|
||||
> **_NOTE:_** Quarkus now ships with a Dev UI, which is available in dev mode only at http://localhost:8080/q/dev/.
|
||||
|
||||
## Packaging and running the application
|
||||
## Packaging and deployment
|
||||
|
||||
The application can be packaged using:
|
||||
```shell script
|
||||
./mvnw package
|
||||
```
|
||||
It produces the `quarkus-run.jar` file in the `target/quarkus-app/` directory.
|
||||
Be aware that it’s not an _über-jar_ as the dependencies are copied into the `target/quarkus-app/lib/` directory.
|
||||
|
||||
If you want to build an _über-jar_, execute the following command:
|
||||
```shell script
|
||||
@@ -29,7 +24,7 @@ If you want to build an _über-jar_, execute the following command:
|
||||
|
||||
The application is now runnable using `java -jar target/quarkus-app/quarkus-run.jar`.
|
||||
|
||||
## Creating a native executable
|
||||
### Creating a native executable
|
||||
|
||||
You can create a native executable using:
|
||||
```shell script
|
||||
@@ -43,16 +38,7 @@ Or, if you don't have GraalVM installed, you can run the native executable build
|
||||
|
||||
You can then execute your native executable with: `./target/buerokalender-0.1.0-SNAPSHOT-runner`
|
||||
|
||||
If you want to learn more about building native executables, please consult https://quarkus.io/guides/maven-tooling.html.
|
||||
|
||||
## Related Guides
|
||||
|
||||
- RESTEasy JAX-RS ([guide](https://quarkus.io/guides/rest-json)): REST endpoint framework implementing JAX-RS and more
|
||||
|
||||
## Provided Code
|
||||
|
||||
### RESTEasy JAX-RS
|
||||
|
||||
Easily start your RESTful Web Services
|
||||
|
||||
[Related guide section...](https://quarkus.io/guides/getting-started#the-jax-rs-resources)
|
||||
Push to docker.io:
|
||||
```shell script
|
||||
./mvnw clean package -DskipTests -Dquarkus.container-image.push=true
|
||||
```
|
||||
39
docker-compose.yml
Normal file
39
docker-compose.yml
Normal file
@@ -0,0 +1,39 @@
|
||||
version: "2.3"
|
||||
|
||||
services:
|
||||
app:
|
||||
image: mattbremer/buerokalender:1
|
||||
environment:
|
||||
- POSTGRES_USER=buerokalender
|
||||
- POSTGRES_PASSWORD=buerokalender
|
||||
- POSTGRES_PORT=5432
|
||||
restart: always
|
||||
networks:
|
||||
- buerokalender
|
||||
ports:
|
||||
- "3004:8080"
|
||||
depends_on:
|
||||
db:
|
||||
condition: service_healthy
|
||||
|
||||
db:
|
||||
image: "postgres:13"
|
||||
mem_limit: 128m
|
||||
environment:
|
||||
- POSTGRES_USER=buerokalender
|
||||
- POSTGRES_PASSWORD=buerokalender
|
||||
healthcheck:
|
||||
test: [ "CMD-SHELL", "pg_isready -U buerokalender" ]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 6
|
||||
# ports:
|
||||
# - "5432:5432"
|
||||
networks:
|
||||
- buerokalender
|
||||
volumes:
|
||||
- ./postgres:/var/lib/postgresql/data
|
||||
|
||||
networks:
|
||||
buerokalender:
|
||||
external: false
|
||||
6
pom.xml
6
pom.xml
@@ -4,7 +4,7 @@
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>de.mbremer</groupId>
|
||||
<artifactId>buerokalender</artifactId>
|
||||
<version>0.1.0-SNAPSHOT</version>
|
||||
<version>1.0.0</version>
|
||||
<properties>
|
||||
<compiler-plugin.version>3.8.1</compiler-plugin.version>
|
||||
<maven.compiler.parameters>true</maven.compiler.parameters>
|
||||
@@ -69,6 +69,10 @@
|
||||
<groupId>io.quarkus</groupId>
|
||||
<artifactId>quarkus-hibernate-validator</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.quarkus</groupId>
|
||||
<artifactId>quarkus-container-image-docker</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.quarkus</groupId>
|
||||
<artifactId>quarkus-junit5</artifactId>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<html lang="de">
|
||||
<head>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<html lang="de">
|
||||
<head>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Database
|
||||
%prod.quarkus.datasource.jdbc.url = jdbc:postgresql://db:5432/buerokalender
|
||||
%prod.quarkus.datasource.username = buerokalender
|
||||
%prod.quarkus.datasource.password = buerokalender
|
||||
%prod.quarkus.datasource.jdbc.url = jdbc:postgresql://db:${POSTGRES_PORT:5432}/buerokalender
|
||||
%prod.quarkus.datasource.username = ${POSTGRES_USER:buerokalender}
|
||||
%prod.quarkus.datasource.password = ${POSTGRES_PASSWORD:buerokalender}
|
||||
%prod.quarkus.datasource.jdbc.max-size=16
|
||||
quarkus.datasource.db-kind=postgresql
|
||||
|
||||
@@ -14,3 +14,8 @@ quarkus.http.auth.form.enabled=true
|
||||
#quarkus.http.auth.session.encryption-key=zHId14V+uiyxmbzhEPCyi7VvbaI80UeEO5yu0H/hVLs=
|
||||
# 24h
|
||||
quarkus.http.auth.form.timeout=86400
|
||||
|
||||
# Deployment
|
||||
quarkus.container-image.additional-tags= 1
|
||||
quarkus.container-image.group = mattbremer
|
||||
quarkus.container-image.name = buerokalender
|
||||
Reference in New Issue
Block a user