Skip to content

Commit

Permalink
Container: Minio angebunden
Browse files Browse the repository at this point in the history
  • Loading branch information
Bernd Ritter committed Apr 21, 2024
1 parent 17f36b7 commit f40a795
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 31 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ Zuerst die Volumes für Postgres und AMQ anlegen
```bash
docker volume create website_my_pgdata
docker volume create amq_journal_data
docker volume create storage_data
```

dann am Holarse Container-Repository anmelden
Expand Down Expand Up @@ -62,6 +63,9 @@ Die Datenbank ist unter http://localhost:5432 erreichbar.
### Mails
Der Mailcatcher ist unter http://localhost:8025 erreichbar.

### S3-Storage
Die Storage-Console (minio) ist unter http://localhost:9001 erreichbar.

### Webseite
Die Webseite ist unter http://localhost:8080/holarseweb/ erreichbar.

Expand Down
54 changes: 27 additions & 27 deletions doc/db2/03_postimport/01-tags-in-taggroups.sql
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
UPDATE tags SET taggroup_id = (SELECT id FROm taggroups WHERE name = 'ENGINE')
@telefoUPDATE tags SET taggroupid = (SELECT id FROm taggroups WHERE code = 'ENGINE')
WHERE name IN (
'Adobe AIR',
'AGS',
'Allegro',
'Build Engine',
'EDuke32',
'FIFEngine',
'Flash',
'FNA',
'Game Maker',
'godot',
'HTML5',
'Irrlicht',
'Ruby',
'Java',
'jMonkeyEngine',
'FIFEngine',
'Flash',
'FNA',
'Game Maker',
'godot',
'HTML5',
'Irrlicht',
'Ruby',
'Java',
'jMonkeyEngine',
'jMonkeyVR',
'Haxeflixel',
'libgdx',
Expand Down Expand Up @@ -46,7 +46,7 @@ WHERE name IN (


-- 2. Franchise tags
UPDATE tags SET taggroup_id = (SELECT id FROM taggroups WHERE name = 'FRANCHISE')
UPDATE tags SET taggroupid = (SELECT id FROM taggroups WHERE code = 'FRANCHISE')
WHERE name IN (
'Anno',
'assasin',
Expand Down Expand Up @@ -75,7 +75,7 @@ WHERE name IN (


-- 3. Licence tags
UPDATE tags SET taggroup_id = (SELECT id FROM taggroups WHERE name = 'LICENSE')
UPDATE tags SET taggroupid = (SELECT id FROM taggroups WHERE code = 'LICENSE')
WHERE name IN (
'Kommerziell',
'Freeware',
Expand All @@ -98,7 +98,7 @@ WHERE name IN (


-- 4. Multiplayer tags (with more multiplayer!)
UPDATE tags SET taggroup_id = (SELECT id FROM taggroups WHERE name = 'MULTIPLAYER')
UPDATE tags SET taggroupid = (SELECT id FROM taggroups WHERE code = 'MULTIPLAYER')
WHERE name IN (
'10+Spieler',
'10-Spieler',
Expand Down Expand Up @@ -175,7 +175,7 @@ WHERE name IN (


-- 5. Platform tags
UPDATE tags SET taggroup_id = (SELECT id FROM taggroups WHERE name = 'PLATFORM')
UPDATE tags SET taggroupid = (SELECT id FROM taggroups WHERE code = 'PLATFORM')
WHERE name IN (
'native',
'amd64',
Expand Down Expand Up @@ -207,7 +207,7 @@ WHERE name IN (


-- 6. Store tags
UPDATE tags SET taggroup_id = (SELECT id FROM taggroups WHERE name = 'STORE')
UPDATE tags SET taggroupid = (SELECT id FROM taggroups WHERE code = 'STORE')
WHERE name IN (
'deliver2',
'GOG',
Expand All @@ -220,7 +220,7 @@ WHERE name IN (


-- 7. Genre tags
UPDATE tags SET taggroup_id = (SELECT id FROM taggroups WHERE name = 'GENRE')
UPDATE tags SET taggroupid = (SELECT id FROM taggroups WHERE code = 'GENRE')
WHERE name IN (
'Arcade',
'Shooter',
Expand Down Expand Up @@ -444,7 +444,7 @@ WHERE name IN (


-- 8. Porter tags
UPDATE tags SET taggroup_id = (SELECT id FROM taggroups WHERE name = 'PORTER')
UPDATE tags SET taggroupid = (SELECT id FROM taggroups WHERE code = 'PORTER')
WHERE name IN (
'Asypr',
'Feral Interactive',
Expand All @@ -458,7 +458,7 @@ WHERE name IN (


-- 9. Package Manager tags
UPDATE tags SET taggroup_id = (SELECT id FROM taggroups WHERE name = 'PACKAGEMANAGER')
UPDATE tags SET taggroupid = (SELECT id FROM taggroups WHERE code = 'PACKAGEMANAGER')
WHERE name IN (
'PPA',
'SNAP',
Expand All @@ -471,14 +471,14 @@ WHERE name IN (
-- 10. Adjustments for the articles and tags (must be run as last instruction!)
-- FIXME: Check if target tag already exists within a tag-set of an article. Maybe window functions?
--- Rename tags if target tag is not yet present
BEGIN TRANSACTION;
UPDATE articles_tags
SET tags_id = (SELECT id FROM tags WHERE name = 'Kommerziell')
WHERE tags_id = (SELECT id FROM tags WHERE name = 'Kommerztiell')
AND article_id NOT IN (SELECT article_id FROM articles_tags WHERE tags_id = (SELECT id FROM tags WHERE name = 'Kommerziell'));
--BEGIN TRANSACTION;
--UPDATE articles_tags
--SET tags_id = (SELECT id FROM tags WHERE name = 'Kommerziell')
--WHERE tags_id = (SELECT id FROM tags WHERE name = 'Kommerztiell')
--AND article_id NOT IN (SELECT article_id FROM articles_tags WHERE tags_id = (SELECT id FROM tags WHERE name = 'Kommerziell'));

DELETE FROM articles_tags WHERE tags_id = (SELECT id FROM tags WHERE name = 'Kommerztiell');
COMMIT;
--DELETE FROM articles_tags WHERE tags_id = (SELECT id FROM tags WHERE name = 'Kommerztiell');
--COMMIT;

UPDATE tags SET name = 'infinite runner' WHERE name = 'infinte runner';

Expand Down Expand Up @@ -606,7 +606,7 @@ DELETE FROM tags WHERE name = 'engine';
COMMIT;

--- Tag assignment
INSERT INTO tags(id, created, name, taggroup_id)
INSERT INTO tags(id, created, name, taggroupid)
VALUES
(nextval('hibernate_sequence'), current_timestamp, 'Feral Store', (SELECT id FROM taggroups WHERE name = 'STORE'));

Expand Down
27 changes: 23 additions & 4 deletions doc/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,29 @@ services:
container_name: amq
restart: always
ports:
- 8161:8161
- 61616:61616
- 8161:8161
- 61616:61616
volumes:
- amq_journal_data:/opt/holaq/data
networks:
- holarse-dev

storage:
image: minio/minio
container_name: minio
restart: always
command: server --console-address ":9001" /data
environment:
MINIO_ROOT_USER: minioadmin
MINIO_ROOT_PASSWORD: minioadmin
ports:
- 9000:9000
- 9001:9001
volumes:
- storage_data:/data
networks:
- holarse-dev

app:
image: tomcat:11.0-jdk21-openjdk
container_name: app
Expand Down Expand Up @@ -64,9 +80,12 @@ services:

volumes:
website_my_pgdata:
external: true
external: true
amq_journal_data:
external: true
external: true
storage_data:
external: true


networks:
holarse-dev:
Expand Down

0 comments on commit f40a795

Please sign in to comment.