Skip to content

Conversation

@unsektor
Copy link

@unsektor unsektor commented Sep 11, 2025

I was inspired by #442 and decided to rework solution for docker setup (docker only, without CI things).

features:

  • setup data could be wiped after successful initialization
  • application data stored in independent volume (to get application new version deploy workflow working perfect)
  • all credentials and settings are stored in .env file

todo:

There few things, which are BLOCKING this MR. Please, DO NOT MERGE until everything done.

  • issue: broken dump setup/db_structure.sql:
    When I tried to load this dump into DB, there were few errors, i went to investigate and researched next:

    • in 112acb2 aowow_articles.quickInfo was removed in DDL, but DML was not changed.
    • in a99fff4 aowow_account.allowExpire was removed in DDL, but DML was not changed.

    I will create another MR with fix of that later. Another MR with fix of that : fix: database dump ddl/dml inconsistency #452

    Off topic: my opinion:
    1. Dump should be split by DML and DDL operations (structure against data)
    2. Dumps should not be changed manually (that's why are migrations for: one update per one migration file)
  • warnings/errors during aowow container initialization process (first run)
    Probably, it depends on extracted data (i didn't extract it from game data, but i used prepared archive from wow-gaming (thanks, feat(docker): add pipeline and docker support #442))
    but i got some warning on setup, it requires some research to understand why they occurred.

    Example of warnings & errors
    Warning: static/uploads/screenshots/normal may be inaccessible to the web service. in /var/www/html/includes/utilities.php on line 904
    
    [ERR]   [build] could not create directory: static/uploads/screenshots/normal/
    [ERR]   finished file generation with errors
    Fatal Error - static/uploads/screenshots/normal may be inaccessible to the web service. @ /var/www/html/includes/utilities.php:904
    
    [WARN]  GlobalStrings.lua not found for locale FR, DE, CN, ES and  RU
    
            [sql] filling aowow_sounds with data
    ...
    [WARN]  [sound] Group [65]    GLUESCREENMEDIUMBUTTONMOUSEUP contains no sound files! Skipping...
    [WARN]  [sound] Group [68]    GLUESCREENLARGEBUTTONMOUSEUP contains no sound files! Skipping...
    [WARN]  [sound] Group [72]    GLUECHECKBOXMOUSEUP contains no sound files! Skipping...
    [WARN]  [sound] Group [75]    GLUECHARCUSTOMIZATIONMOUSEUP contains no sound files! Skipping...
    [WARN]  [sound] Group [78]    GLUESCROLLBUTTONMOUSEUP contains no sound files! Skipping...
    [WARN]  [sound] Group [92]    GAMESCREENSMALLBUTTONMOUSEUP contains no sound files! Skipping...
    [WARN]  [sound] Group [93]    GAMESCREENSMALLBUTTONMOUSEOVER contains no sound files! Skipping...
    [WARN]  [sound] Group [95]    GAMESCREENMEDIUMBUTTONMOUSEUP contains no sound files! Skipping...
    [WARN]  [sound] Group [96]    GAMESCREENMEDIUMBUTTONMOUSEOVER contains no sound files! Skipping...
    [WARN]  [sound] Group [98]    GAMESCREENLARGEBUTTONMOUSEUP contains no sound files! Skipping...
    [WARN]  [sound] Group [99]    GAMESCREENLARGEBUTTONMOUSEOVER contains no sound files! Skipping...
    [WARN]  [sound] Group [103]   GAMEHIGHLIGHTFRIENDLYUNIT contains no sound files! Skipping...
    [WARN]  [sound] Group [104]   GAMEHIGHLIGHTHOSTILEUNIT contains no sound files! Skipping...
    [WARN]  [sound] Group [105]   GAMEHIGHLIGHTNEUTRALUNIT contains no sound files! Skipping...
    [WARN]  [sound] Group [106]   GAMEINITIALATTACK contains no sound files! Skipping...
    [WARN]  [sound] Group [897]   GAMEHIGHLIGHTHOSTILEUNIT contains no sound files! Skipping...
    [WARN]  [sound] Group [898]   GAMEHIGHLIGHTNEUTRALUNIT contains no sound files! Skipping...
    [WARN]  [sound] Group [899]   GAMEHIGHLIGHTFRIENDLYUNIT contains no sound files! Skipping...
    ...
    [sound] * batch #9 (1000)19:16:57  [WARN]  [sound] Group [13401] Zap 00 has invalid sound file ID_Forge_Zap04 on index 1! Skipping...
    [WARN]  [sound] Group [13401] Zap 00 contains no sound files! Skipping...
    ...
    [sound] - linking to emotes
    [sound] - linking to creatures
    [sound] - linking to spells
    [sound] - linking to zones
    [sound] - linking to items
    [sound] - linking to screen effects
    [OK]    [sql] subscript 'sounds' returned successfully
    
            [sql] filling aowow_spell with data
    ...
    [WARN]  [spell] [54292] could not match Glyph of the White Bear with affected spells
    [WARN]  [spell] [58132] could not match Glyph of the Black Bear with affected spells
    [WARN]  [spell] [58686] could not match Glyph of the Ghoul with affected spells
    [OK]    [sql] subscript 'spell' returned successfully
    
            [sql] filling aowow_spawns with data
             * 1/6: `creature` spawns - 146717 / 151327 (97.0%)19:49:02  [WARN]  [points] [106934]  could not be matched to displayable area [A:0; X:85.6123; Y:239.877]
             * 2/6: `gameobject` spawns - 79028 / 92603 (85.3%)19:57:57  [WARN]  [points] [76888]   could not be matched to displayable area [A:0; X:-16126.7; Y:16285]
             * 3/6: SoundEmitters.dbc positions - 316 / 632 (50.0%)19:59:15  [WARN]  [points] [1735]    could not be matched to displayable area [A:0; X:-4860.77; Y:1232.73]
             * 4/6: AreaTrigger.dbc positions and teleporter endpoints -  797 / 1504 (53.0%)19:59:21  [WARN]  [points] [4958]    could not be matched to displayable area [A:0; X:-12969.5; Y:-15914.1]
             * 6/6: NPC waypoints from `script_waypoint`, `waypoints` & `waypoint_data` -   5754 / 146643 ( 3.9%)19:59:53  [WARN]  [points] [26335]   with path/point [3681; 1] could not be matched to displayable area [A:0; X:-393.202; Y:-265.345]
    [WARN]  [points] [26336]   with path/point [3681; 1] could not be matched to displayable area [A:0; X:-393.202; Y:-265.345]
    * 6/6: NPC waypoints from `script_waypoint`, `waypoints` & `waypoint_data` -   5756 / 146643 ( 3.9%)19:59:53  [WARN]  [points] [26337]   with path/point [3681; 1] could not be matched to displayable area [A:0; X:-393.202; Y:-265.345]
    
    [ERR]   [sql] subscript 'emotes' returned with errors
    [ERR]   finished sql generation with errors
    
  • feature: Built data saved to independent volume

  • issue: Too many images are 404

  • issue: JavaScript error on each page (alert with text could not fetch static data: item-scaling)

  • testing:

    • every client data is available (static assets, etc ...)
    • security: check everything is closed for public access (.htaccess, etc ...)
    • production build working correctly
    • ... [TODO]
  • enhancement: code cleanup


... Further roadmap:

  • Dockerize related projects (to build setup data from scratch), integrate them to here (e.g. MPQExtractor, media conversation, etc.)

I have managed to make it work, but I feel like it still needs a bit of touch to become finally finished.
What do you think ?

P.S.

I remember this project when I was young (it was in 2010x), and this project is GOLD.
I'm glad to see it's alive. Huge thanks to @Sarjuuk and maintainers for your job. You are awesome.

@Sarjuuk Sarjuuk added the Feature request i want something that is missing label Sep 26, 2025
@unsektor unsektor force-pushed the feature/docker-support branch from d07564a to d3f92b8 Compare September 28, 2025 11:08
@unsektor
Copy link
Author

unsektor commented Sep 28, 2025

Here is an update to get master branch working in Docker, but I will leave this PR still in Draft, because even it's working, there are things I am not really satisfied with:

  • compose*.yaml files (tracked by git) changing required:
    aowow container should not contain extracted client game data, instead of that, related path should be mounted
    to the container. At this moment it's required to change docker-compose file (see README).
    I think one of next ways could be a solution to this:
    1. (too general) compose*.yaml files should contain .dist extension
    2. (too concrete) use environment variable to set path in .env files instead of changing .yaml.
  • workaround to ignore TLS error on connection to mysql from aowow service.
    Should be fixed correctly, instead of ignoring it.
  • WET configuration environment files.
    At this moment .env files requires to copy same values for few variables (because of design to separate environments between services)
  • Implicit attribute to determine was aowow setup done or not, at this moment it is implemented just by a database existence check.
  • I was unable to setup aowow fully, because:
    1. I was unable to extract .dbc files using the only MPQExtractor.
      I played with data from feat(docker): add pipeline and docker support #442 and with my old data extracted by MaNGOS maps extractor.
      Is it correct?
    2. MPQExtractor didn't produce some required data for installation from my client game files.
      I didn't get Data/Interface files (=> no icons in static directory)
      Have no idea why: files were not overwritten, they simply were not extracted.
      Probably, it's problem with my data and this should not block this PR.
  • I'm not really sure, should initialization script downloads prepared assets from somewhere or not.
    At this moment, prepared assets hosted on a 3rd-party project, which is not related to this project explicitly.
    Otherwise, it's fancy and nice, isn't it ? Also project could keep this feature, but change URL to blank, for example.
  • Built data is not stored in independent volume because of configuration complexity.
    To make this working perfect I think it's better to isolate source code, configurations and assets from same directory, in the future.
  • I'm not sure that script
    php ./aowow --sql
    php ./aowow --build
    is enough to get setup process done fully.
  • Complex testing of changes is not done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Feature request i want something that is missing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants