Skip to content

Commit

Permalink
Merge pull request #241 from micromata/Release-8.1-SNAPSHOT
Browse files Browse the repository at this point in the history
Release 8.1 snapshot
  • Loading branch information
kreinhard authored Dec 29, 2024
2 parents 6265f31 + 9675aaf commit 9dc4e92
Show file tree
Hide file tree
Showing 136 changed files with 3,564 additions and 2,180 deletions.
6 changes: 3 additions & 3 deletions README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ You may use PostgreSQL instead of the built-in data base.
* Choose and set a database password: +
`export PGPASSWORD=mypassword`
* Run PostgreSQL: +
`docker run --name projectforge-postgres -p 127.0.0.1:5432:5432 -e POSTGRES_PASSWORD=$PGPASSWORD -e POSTGRES_USER=projectforge -d postgres:13.9`
`docker run --name projectforge-postgres -p 127.0.0.1:5432:5432 -e POSTGRES_PASSWORD=$PGPASSWORD -e POSTGRES_USER=projectforge -d postgres:13.18`
* Configure ProjectForge

.$HOME/ProjectForge/projectforge.properties
Expand All @@ -96,8 +96,8 @@ spring.datasource.driver-class-name=org.postgresql.Driver
|===
|Stop|`docker stop projectforge-postgres`
|Start|`docker start projectforge-postgres`
|Import dump (optional)|`docker run -v ~/ProjectForgeBackup/pf.sql:/mnt/pf.sql -e PGPASSWORD=$PGPASSWORD -it --rm --link projectforge-postgres:postgres postgres:13.9 psql -h postgres -U projectforge -q -f /mnt/pf.sql 2>&1 > log.txt`
|PSQL|`docker run -e PGPASSWORD=$PGPASSWORD -it --rm --link projectforge-postgres:postgres postgres:13.9 psql -h postgres -U projectforge`
|Import dump (optional)|`docker run -v ~/ProjectForgeBackup/pf.sql:/mnt/pf.sql -e PGPASSWORD=$PGPASSWORD -it --rm --link projectforge-postgres:postgres postgres:13.18 psql -h postgres -U projectforge -q -f /mnt/pf.sql 2>&1 > log.txt`
|PSQL|`docker run -e PGPASSWORD=$PGPASSWORD -it --rm --link projectforge-postgres:postgres postgres:13.18 psql -h postgres -U projectforge`
|Reset passwords (optional)|`update t_pf_user_password SET password_hash='SHA{BC871652288E56E306CFA093BEFC3FFCD0ED8872}', password_salt=null; update t_pf_user SET password='SHA{BC871652288E56E306CFA093BEFC3FFCD0ED8872}', password_salt=null, email='m.developer@localhost';` +
password is now `test123`.
|Clear calendar subscriptions (optional)|`update t_calendar set ext_subscription=false where owner_fk != ###;` +
Expand Down
41 changes: 34 additions & 7 deletions Migration-ToDo.adoc → ToDo.adoc
Original file line number Diff line number Diff line change
@@ -1,22 +1,24 @@
Aktuell:
- Groovy-scripts: remove or fix.
- AG-Grid: setColumnStates wird nicht in den UserPrefs gespeichert.
- Wicket: Auftragsbuch: org.apache.wicket.core.request.mapper.StalePageException: A request to page '[Page class = org.projectforge.web.fibu.AuftragEditPage, id = 9, render count = 3]' has been made with stale 'renderCount'. The page will be re-rendered.
- -XX:ReservedCodeCacheSize=100m
- History: Rechnungsposition -> Auftragsposition taucht nicht in History auf.
- QueryFilter.sortAndLimitMaxRowsWhileSelect: not yet supported
- Gradle-Version-Checker: Read lib.versions.toml und Vergleichen mit fatjar.
- Fehlerhinweis, wenn halber Tag für Urlaubsanfang/ende gewählt wird, es aber kein Arbeitstag ist.
- Scripts
- Kalendereinträge und Subscriptions.
- LoginProtection: Increases penalty time for DAV only after 5 tries.

- Auftragsbuch nächtlich persistieren (als json-zip) für Forecast-Vergleiche.
- Apple for Webauthn4j
- Abwesenheiten
- Fakturaquote Monatsbericht
- Google-Calendar-Integration
- Pagination of selects: Aktuell wird nicht DB-seitig paginiert, sondern immer die ganze Liste gefetched.
- remove all BaseDO.xxxId (lazy fetch) and replace callee by baseDO?.id
- Entitygraphen nutzen: ConflictVacationCache, AuftragCache etc.
- Auftrag editieren: massenhaft SQLs
- employeeSalaryList: lädt wie blöde nach dem Editieren. (Excel-Exports auch zuviele SQLs)
- AddressKampagnen: ebd. (massenhaft SQLs)
- Suche nach Kontonummer in KontoDO
- Lazy-Breakpoint: AbstractLazyInitializer.initialize (#170)
org.hibernate.persister.entity.AbstractEntityPersister#generateSelectLazy:
Expand All @@ -25,7 +27,6 @@ History
- Positionen etc. vernünftig anzeigen.

- Suche:
- Suche in History
- Suche nach K+S (aktuell noch Provisorium)
- HistoryConvertContext: Am Ende alle displayProperties übernehmen.
Expand All @@ -42,11 +43,37 @@ History
Später
- Hibernate-Search: K+S etc.
- Milton
- Besuchsbuch und EmployeeValidSinceAttr: DisplayEntries von Besuchtagen mit Datum des Besuchs versehen.
- Suche-Seite hat veraltete Bereiche, AddressListPage läuft auf Fehler.
- OrderExport: paymentSchedules werden gefetcht.
- Update caches after single load or modification.

Ganz später
- Kalenderlist ruft x-fach DB: FIND GroupDO resultClass=GroupDO auf.

Postgresql-Dump-Imports bechleunigen:

ALTER SYSTEM SET fsync = off;
ALTER SYSTEM SET synchronous_commit = off;
SET maintenance_work_mem = '512MB';
drop view v_t_pf_user;

Rancher

docker system df
docker system prune -a --volumes
docker system df
docker volume ls
docker volume rm <volume-name>


Orderbooks importieren:
docker cp ~/ProjectForgeBackup/ProjectForge-Orderbook_*.gz projectforge-postgres:/tmp/

\set file_path '/tmp/ProjectForge-Orderbook_2023-11-01.gz'
INSERT INTO t_fibu_orderbook_storage (date, serialized_orderbook) VALUES ('2023-11-01', pg_read_binary_file(:'file_path')::bytea);
\set file_path '/tmp/ProjectForge-Orderbook_2023-12-01.gz'
INSERT INTO t_fibu_orderbook_storage (date, serialized_orderbook) VALUES ('2023-12-01', pg_read_binary_file(:'file_path')::bytea);


SELECT date, octet_length(serialized_orderbook) AS byte_count FROM t_fibu_orderbook_storage;
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ plugins {

allprojects {
group = "org.projectforge"
version = "8.0" // Update version string here (nowhere else)
version = "8.1-SNAPSHOT" // Update version string here (nowhere else)

repositories {
mavenCentral()
Expand Down
8 changes: 8 additions & 0 deletions docker/compose/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
POSTGRES_USER=projectforge
POSTGRES_PASSWORD=supersecurepassword
POSTGRES_DB=projectforge
DB_HOST=db
DB_PORT=5432

APP_PORT=8080
DOMAIN=mydomain.com
25 changes: 25 additions & 0 deletions docker/compose/README.TXT
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
In progress

Dirctories:
project/
├── ProjectForge/ # Application
├── ProjectForge/database # Database
├── nginx/ # Nginx configuration
├── docker-compose.yml # Docker Compose setup
└── .env # Evirnoment variables


Edit .env, ./nginx/nginx.conf

Deploy SSL certificates

For example, use Let’s Encrypt with Certbot to generate SSL certificates and store them in nginx/certs and nginx/keys.

Start the application with:
docker-compose up -d

Check running containers:
docker ps
docker-compose logs


49 changes: 35 additions & 14 deletions docker/compose/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,48 @@
version: "3.7"
version: "3.8"
services:
projectforge-app:
image: micromata/projectforge
image: micromata/projectforge:latest
container_name: projectforge-app
restart: always
ports:
- "127.0.0.1:8080:8080"
volumes:
- ${HOME}/ProjectForge:/ProjectForge
environment:
# DOCKER_OPTS: so don't offer embedded data-base in setup wizard:
# DOCKER_OPTS: so don't offer embedded database in setup wizard:
- DOCKER_OPTS="-Ddocker=stack"
#- DB_HOST=${DB_HOST}
#- DB_PORT=${DB_PORT}
#- POSTGRES_USER=${POSTGRES_USER}
#- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
#- POSTGRES_DB=${POSTGRES_DB}
ports:
#- "127.0.0.1:${APP_PORT}:8080"
- "${APP_PORT}:8080"
#volumes:
# - ${HOME}/ProjectForge:/ProjectForge
depends_on:
- projectforge-db

projectforge-db:
image: postgres:13.9
image: postgres:13.18
container_name: projectforge-db
restart: always
ports:
- "127.0.0.1:5432:5432"
#ports:
# - "127.0.0.1:5432:5432"
volumes:
- ${HOME}/ProjectForgeDB:/var/lib/postgresql/data
- ./ProjectForgeDB:/var/lib/postgresql/data
environment:
- POSTGRES_PASSWORD=***password***
- POSTGRES_USER=projectforge
- PGDATA=/var/lib/postgresql/data/pgdata
- POSTGRES_USER=${POSTGRES_USER}
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
- POSTGRES_DB=${POSTGRES_DB}

nginx:
image: nginx:latest
container_name: nginx
restart: always
ports:
- "80:80"
- "443:443"
volumes:
- ./nginx/nginx.conf:/etc/nginx/nginx.conf
- ./nginx/certs:/etc/ssl/certs
- ./nginx/keys:/etc/ssl/private
depends_on:
- projectforge-app
21 changes: 21 additions & 0 deletions docker/compose/nginx/nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
server {
listen 80;
server_name ${DOMAIN};
return 301 https://$host$request_uri;
}

server {
listen 443 ssl;
server_name ${DOMAIN};

ssl_certificate /etc/ssl/certs/fullchain.pem;
ssl_certificate_key /etc/ssl/private/privkey.pem;

location / {
proxy_pass http://app:8000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
4 changes: 2 additions & 2 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,14 @@ org-postgresql = "42.7.4"
org-reflections = "0.10.2"
org-springframework-boot = "3.3.6"
org-apache-tomcat-embed = "10.1.33" # must match spring-boot
org-springframework-spring = "6.1.15"
org-springframework-spring = "6.1.16"
org-springframework-security = "6.4.1"
org-wicketstuff-html5 = "10.2.0"
org-wicketstuff-select2 = "10.2.0"
se-sawano-java-alphanumeric-comparator = "1.4.1"

# logging
ch-qos-logback = "1.5.12"
ch-qos-logback = "1.5.15"
io-github-microutils-kotlin-logging = "3.0.5"
jboss-logging = "3.6.0.Final"
org-apache-logging-log4j = "2.24.2" # Needed by poi.
Expand Down
Loading

0 comments on commit 9dc4e92

Please sign in to comment.