Skip to content

Commit fa3a772

Browse files
Merge pull request #552 from mangalap123/develop
#526 Update Habitat build to initialize/set 'parameters' env variable
2 parents a8c21bc + 05241fc commit fa3a772

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

habitat/hooks/run

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
#!/bin/sh
22
export HOME="/hab/svc/chime/config"
33
# export the parameters file path
4-
export PARAMETERS="${pkg_prefix}/defaults/webapp.cfg"
4+
export PARAMETERS="{{pkg.path}}/defaults/webapp.cfg"
55
cd "/hab/svc/chime"
66

77
if [ "$(whoami)" = "root" ]; then
88
exec chpst \
99
-U root:hab \
1010
-u root:hab \
11-
streamlit run "{{pkg.path}}/app.py" 2>&1
11+
streamlit run "{{pkg.path}}/st_app.py" 2>&1
1212
else
13-
exec streamlit run "{{pkg.path}}/app.py" 2>&1
13+
exec streamlit run "{{pkg.path}}/st_app.py" 2>&1
1414
fi

habitat/plan.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,10 @@ do_build() {
6666
}
6767

6868
do_install() {
69+
mkdir "${pkg_prefix}/defaults/"
6970
cp -pr ${PLAN_CONTEXT}/../src/* "${pkg_prefix}/"
70-
cp -pr ${PLAN_CONTEXT}/../deafults/webapp.cfg "${pkg_prefix}/defaults/"
71+
cp -pr ${PLAN_CONTEXT}/../st_app.py "${pkg_prefix}/"
72+
cp -pr ${PLAN_CONTEXT}/../defaults/webapp.cfg "${pkg_prefix}/defaults/"
7173
return $?
7274
}
7375

0 commit comments

Comments
 (0)