Skip to content

Commit

Permalink
fix start process and packages
Browse files Browse the repository at this point in the history
  • Loading branch information
zmraul committed Nov 19, 2024
1 parent 853be14 commit 1d5b1a6
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 12 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -92,11 +92,11 @@ jobs:
# skopeo
sudo snap install --devmode --channel edge skopeo
sudo snap install yq
- name: Create local image
run: |
version="$(cat rockcraft.yaml | yq .version)"
sudo skopeo \
--insecure-policy \
copy \
Expand Down
16 changes: 11 additions & 5 deletions rockcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,13 @@ parts:
opensearch-snap:
plugin: nil
stage-snaps:
- opensearch/2/edge
- opensearch/2/edge/core2404
stage-packages:
- base-files
- python3-venv
- python3-yaml
- curl
- util-linux
override-prime: |
craftctl default
Expand Down Expand Up @@ -81,8 +87,8 @@ parts:
plugin: dump
source: scripts
organize:
start.sh: bin/start.sh
set_conf.py: bin/set_conf.py
start.sh: usr/bin/start.sh
set_conf.py: usr/bin/set_conf.py
stage:
- bin/start.sh
- bin/set_conf.py
- usr/bin/start.sh
- usr/bin/set_conf.py
6 changes: 1 addition & 5 deletions scripts/start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,4 @@ sed -i "s@=logs/@=${OPENSEARCH_VARLOG}/@" "${OPENSEARCH_PATH_CONF}/jvm.options"

cat "${conf}"

exec /usr/bin/setpriv \
--clear-groups \
--reuid opensearch \
--regid opensearch \
-- "${OPENSEARCH_BIN}"/opensearch
exec "${OPENSEARCH_BIN}"/opensearch

0 comments on commit 1d5b1a6

Please sign in to comment.