Commit Graph

28 Commits

Author SHA1 Message Date
Daniel Șerbănescu
50a3fdd03c wordpress: fixed installing of languages 2023-07-04 21:20:42 +02:00
Colin Arnott
64f3a304db
nixos/wordpress: ensure default sites includes a theme 2023-01-28 10:31:56 +00:00
Jonas Heinrich
748c2b416c
nixos/wordpress: fix minor syntax error 2023-01-27 16:35:46 +01:00
Colin Arnott
66e0e5ad74
nixos/wordpress: plugins and themes as attrs
In an effort to better encode version strings and use descriptive pnames
that do not conflict with top level pkgs, we currently use
wordpress-${type}-${pname} for pname. This is good for the nix store,
but when we synthesize the wordpress derivation in our module, we reuse
this pname for the output directory.

Internally wordpress can handle this fine, since plugins must register
via php, not directory. Unfortunately, many plugins like civicrm and
wpforms-lite are designed to rely upon the name of their install
directory for homing or discovery.

As such, we should follow both the upstream convention and
services.nextcloud.extraApps and use an attribute set for these options.
This allows us to not have to deal with the implementation details of
plugins and themes, which differ from official and third party, but also
give users the option to override the install location. The only issue
is that it breaks the current api.
2023-01-27 15:24:19 +00:00
Jonas Heinrich
c51dd42311 nixos/wordpress: add settings option 2023-01-16 14:06:10 +01:00
Maximilian Bosch
b40b8b92e2
nixos/wordpress: ensure that fonts already exists
Not a big deal in most of the cases because wordpress ensures that this
directory exists on its own, but with our twentig customizations that's
actually causing issues.

(cherry picked from commit 3285342bfe5f401dda84c13c834e73154928a61c)
2022-11-07 10:08:01 +01:00
Maximilian Bosch
5afde0064a
nixos/wordpress: make fonts directory writable
Needed to host e.g. google fonts locally.
2022-10-13 17:30:22 +02:00
Jonas Heinrich
b881869205 nixos/wordpress: Add language support 2022-10-01 00:44:32 +09:00
pennae
722b99bc0e nixos/*: convert options with admonitions to MD
rendering changes only slightly, most changes are in spacing.
2022-08-31 16:36:16 +02:00
pennae
087472b1e5 nixos/*: automatically convert option docs 2022-08-06 20:39:12 +02:00
pennae
3aebb4a2be nixos/*: normalize link format
make (almost) all links appear on only a single line, with no
unnecessary whitespace, using double quotes for attributes. this lets us
automatically convert them to markdown easily.

the few remaining links are extremely long link in a gnome module, we'll
come back to those at a later date.
2022-08-03 21:57:46 +02:00
Jonas Heinrich
c95e816c65
nixos/wordpress: Drop old deprecated interface (#152674) 2022-01-23 23:17:01 +09:00
Jonas Heinrich
ef0de7ccb5
nixos/wordpress: Ensure no passwordFile if local db deployment (#148613) 2022-01-12 21:50:19 +09:00
Moritz Hedtke
bb358d6566
nixos/wordpress: Disable directory indexes
Fixes #151159
Confirmed using path http://localhost/wp-includes/
2022-01-06 18:04:19 +01:00
Naïm Favier
2ddc335e6f
nixos/doc: clean up defaults and examples 2021-10-04 12:47:20 +02:00
Jonas Heinrich
38431cf21c nixos/wordpress: caddy support 2021-09-17 19:12:21 +09:00
Jean-Philippe Braun
d4eca42de4 nixos/wordpress: nginx support 2021-07-16 08:51:08 +02:00
Martin Weinelt
724ed08df0
nixos/wordpress: regenerate secret keys if misspelled key name is found
A secret key generated by the nixos module was misspelled, which could
possibly impact the security of session cookies.

To recover from this situation we will wipe all security keys that were
previously generated by the NixOS module, when the misspelled one is
found. This will result in all session cookies being invalidated. This
is confirmed by the wordpress documentation:

> You can change these at any point in time to invalidate all existing
> cookies. This does mean that all users will have to login again.

https://wordpress.org/support/article/editing-wp-config-php/#security-keys

Meanwhile this issue shouldn't be too grave, since the salting function
of wordpress will rely on the concatenation of both the user-provided
and automatically generated values, that are stored in the database.

> Secret keys are located in two places: in the database and in the
> wp-config.php file. The secret key in the database is randomly
> generated and will be appended to the secret keys in wp-config.php.

https://developer.wordpress.org/reference/functions/wp_salt/

Fixes: 2adb03fdae ("nixos/wordpress:
generate secrets locally")

Reported-by: Moritz Hedtke <Moritz.Hedtke@t-online.de>
2021-05-29 04:24:42 +02:00
Ben Siraphob
4f0cdb68d7 treewide: unzip buldInputs to nativeBuildInputs (2) 2021-03-06 15:18:05 +07:00
Pavol Rusnak
fadcfc3ea4
treewide: per RFC45, remove more unquoted URLs 2020-04-18 14:04:37 +02:00
Aaron Andersen
01ccb67598 nixos/httpd: code cleanup 2020-01-31 20:39:12 -05:00
Aaron Andersen
79215f0df1 nixos/httpd: limit serving web content to virtual hosts, convert virtualHosts option type from listOf to attrsOf, add ACME integration 2019-12-24 20:27:48 -05:00
Jason Samsa
7e564ae162 remove vulgarity from wordpress nixos module 2019-12-04 12:45:40 -06:00
Janne Heß
d6c08776ba treewide: Switch to system users 2019-10-12 22:25:28 +02:00
Martin Milata
2adb03fdae nixos/wordpress: generate secrets locally
Use /dev/urandom to generate keys and salts instead of downloading them
from https://api.wordpress.org/secret-key/1.1/salt/
2019-09-22 14:33:08 +02:00
volth
08f68313a4 treewide: remove redundant rec 2019-08-28 11:07:32 +00:00
Aaron Andersen
400c6aac71 nixos/phpfpm: deprecate extraConfig options in favor of settings options 2019-08-23 07:56:27 -04:00
Aaron Andersen
aa05aad470 nixos/wordpress: create module to replace the httpd subservice 2019-07-03 11:47:33 -04:00