Skip to content

Commit

Permalink
remove OpenSearch build.sh: moved to OpenSearch repo
Browse files Browse the repository at this point in the history
`build.sh` has been copied over to all active branches(*) of the
OpenSearch repo and can now consequently be deleted here. this means,
that from now on, the scripts from the respository will be picked up.

for more information on the order of evaluation of the custom build
scripts, see the [documentation][].

this gives the advantage to have branch-specific new logic in place
there. this has already been used to add the no-jdk targets to the
builds on main and 2.x.

two tests were based on the assumption that there would be a `build.sh`
for OpenSearch in this repository, however these are generic tests and
just used OpenSearch as an example. they have been switched to be based
on OpenSearch-Dashboards instead which - for the time being - still has
its own `build.sh` here.

(*): the following branches have been considered as active:
- main
- 2.x
- 2.3
- 1.x
- 1.3

this is part of opensearch-project#99

[documentation]: https://github.com/opensearch-project/opensearch-build/tree/main/src/build_workflow#custom-build-scripts

Signed-off-by: Ralph Ursprung <Ralph.Ursprung@avaloq.com>
  • Loading branch information
rursprung committed Nov 1, 2022
1 parent 9a48acc commit 6f52e99
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 165 deletions.
161 changes: 0 additions & 161 deletions scripts/components/OpenSearch/build.sh

This file was deleted.

8 changes: 4 additions & 4 deletions tests/tests_paths/test_script_finder.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ def test_find_build_script_opensearch_dashboards_default(self) -> None:

def test_find_build_script_component_override(self) -> None:
self.assertEqual(
os.path.join(ScriptFinder.component_scripts_path, "OpenSearch", "build.sh"),
ScriptFinder.find_build_script("OpenSearch", "OpenSearch", self.component_without_scripts),
os.path.join(ScriptFinder.component_scripts_path, "OpenSearch-Dashboards", "build.sh"),
ScriptFinder.find_build_script("OpenSearch-Dashboards", "OpenSearch-Dashboards", self.component_without_scripts),
msg="A component without scripts resolves to a component override.",
)

Expand All @@ -60,8 +60,8 @@ def test_find_build_script_component_script_in_folder(self) -> None:

def test_find_build_script_component_script_in_folder_with_default(self) -> None:
self.assertEqual(
os.path.join(ScriptFinder.component_scripts_path, "OpenSearch", "build.sh"),
ScriptFinder.find_build_script("OpenSearch", "OpenSearch", self.component_with_scripts_folder),
os.path.join(ScriptFinder.component_scripts_path, "OpenSearch-Dashboards", "build.sh"),
ScriptFinder.find_build_script("OpenSearch-Dashboards", "OpenSearch-Dashboards", self.component_with_scripts_folder),
msg="A component with a scripts folder resolves to the override.",
)

Expand Down

0 comments on commit 6f52e99

Please sign in to comment.