mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-12-07 05:27:13 -06:00
feat: fixed opensearch and elasticsearch
This commit is contained in:
parent
8c4d36d89b
commit
81af972cca
1 changed files with 26 additions and 2 deletions
|
|
@ -322,9 +322,33 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
mastodon-init-db.serviceConfig.EnvironmentFile = "/var/lib/mastodon/.secrets_env";
|
mastodon-init-db.serviceConfig.EnvironmentFile = "/var/lib/mastodon/.secrets_env";
|
||||||
systemd-tmpfiles-setup.after = [ "var-lib-mastodon.mount" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
|
systemd-tmpfiles-setup.after = [ "var-lib-mastodon.mount" ];
|
||||||
|
|
||||||
|
opensearch-install-plugins = {
|
||||||
|
description = "Install OpenSearch plugins";
|
||||||
|
before = [ "opensearch.service" ];
|
||||||
|
requiredBy = [ "opensearch.service" ];
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "oneshot";
|
||||||
|
RemainAfterExit = true;
|
||||||
|
};
|
||||||
|
script = ''
|
||||||
|
PLUGIN_DIR="/var/lib/opensearch/plugins/analysis-icu"
|
||||||
|
if [ ! -d "$PLUGIN_DIR" ]; then
|
||||||
|
# Create the plugins directory if it doesn't exist
|
||||||
|
mkdir -p /var/lib/opensearch/plugins
|
||||||
|
|
||||||
|
# Install using the proper OpenSearch plugin command
|
||||||
|
export OPENSEARCH_JAVA_HOME="${pkgs.jdk17}/lib/openjdk"
|
||||||
|
${pkgs.opensearch}/bin/opensearch-plugin install --batch analysis-icu || {
|
||||||
|
echo "Plugin installation failed, but continuing anyway"
|
||||||
|
exit 0
|
||||||
|
}
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
timers.fedifetcher = {
|
timers.fedifetcher = {
|
||||||
description = "Timer for FediFetcher";
|
description = "Timer for FediFetcher";
|
||||||
wantedBy = [ "timers.target" ];
|
wantedBy = [ "timers.target" ];
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue