diff --git a/install_wiki.yaml b/install_wiki.yaml index 0556dbd..6c0fafe 100644 --- a/install_wiki.yaml +++ b/install_wiki.yaml @@ -4,7 +4,126 @@ become: true tasks: - + + - name: set LocalSettings.php + blockinfile: + path: /root/LocalSettings.php + state: present + create: true + owner: "root" + group: "root" + mode: "0666" + marker: "{mark}" + marker_begin: " "$wgResourceBasePath/resources/assets/change-your-logo.svg", + 'icon' => "$wgResourceBasePath/resources/assets/change-your-logo.svg", + ]; + + ## UPO means: this is also a user preference option + + $wgEnableEmail = false; + $wgEnableUserEmail = true; # UPO + + $wgEmergencyContact = ""; + $wgPasswordSender = ""; + + $wgEnotifUserTalk = false; # UPO + $wgEnotifWatchlist = false; # UPO + $wgEmailAuthentication = true; + + ## Database settings + $wgDBtype = "mysql"; + $wgDBserver = "mariadb"; + $wgDBname = "my_wiki"; + $wgDBuser = "wikiuser"; + $wgDBpassword = "{{ sqlpwd }}"; + + # MySQL specific settings + $wgDBprefix = ""; + $wgDBssl = false; + + # MySQL table options to use during installation or update + $wgDBTableOptions = "ENGINE=InnoDB, DEFAULT CHARSET=binary"; + + # Shared database table + # This has no effect unless $wgSharedDB is also set. + $wgSharedTables[] = "actor"; + + ## Shared memory settings + $wgMainCacheType = CACHE_ACCEL; + $wgMemCachedServers = []; + + ## To enable image uploads, make sure the 'images' directory + ## is writable, then set this to true: + $wgEnableUploads = true; + $wgUseImageMagick = true; + $wgImageMagickConvertCommand = "/usr/bin/convert"; + $wgUseInstantCommons = false; + $wgPingback = false; + $wgLanguageCode = "en"; + $wgLocaltimezone = "UTC"; + + ## Set $wgCacheDirectory to a writable directory on the web server + ## to make your wiki go slightly faster. The directory should not + ## be publicly accessible from the web. + #$wgCacheDirectory = "$IP/cache"; + + $wgSecretKey = "68876c5ab7953361002cc0afd46371202badcf9aa4241976eafe44ac3e330e09"; + + # Changing this will log out all existing sessions. + $wgAuthenticationTokenVersion = "1"; + + # Site upgrade key. Must be set to a string (default provided) to turn on the + # web installer while LocalSettings.php is in place + $wgUpgradeKey = "76691fca3e2c1fff"; + + ## For attaching licensing metadata to pages, and displaying an + ## appropriate copyright notice / icon. GNU Free Documentation + ## License and Creative Commons licenses are supported so far. + $wgRightsPage = ""; # Set to the title of a wiki page that describes your license/copyright + $wgRightsUrl = ""; + $wgRightsText = ""; + $wgRightsIcon = ""; + + # Path to the GNU diff3 utility. Used for conflict resolution. + $wgDiff3 = "/usr/bin/diff3"; + + $wgDefaultSkin = "monobook"; + wfLoadSkin( 'MinervaNeue' ); + wfLoadSkin( 'MonoBook' ); + wfLoadSkin( 'Timeless' ); + wfLoadSkin( 'Vector' ); + + + - name: remove other files include_tasks: yaml_sub/myrepo_clean.yaml @@ -24,7 +143,7 @@ - name: remove other files include_tasks: yaml_sub/install_docker.yaml - - name: Create network AuthentikNet + - name: Create network WikiNet community.docker.docker_network: name: WikiNet @@ -74,10 +193,7 @@ networks: strict volumes: - "wiki_images:/var/www/html/images" - - # After initial setup, download LocalSettings.php to the same directory as - # this yaml and uncomment the following line and use compose to restart - # the mediawiki service - # - ./LocalSettings.php:/var/www/html/LocalSettings.php + - "/root/LocalSettings.php:/var/www/html/LocalSettings.php" +