mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2024-12-24 07:46:41 +00:00
Add production mode guards.
This commit is contained in:
parent
3bad30eff7
commit
0495053fd5
12
deps.sh
12
deps.sh
@ -1,8 +1,10 @@
|
|||||||
# Deploy key for private npm modules
|
if [ $NODE_ENV == 'production' ]; then
|
||||||
mkdir -p /root/.ssh
|
# Deploy key for private npm modules
|
||||||
cp deploy_key /root/.ssh/id_rsa
|
mkdir -p /root/.ssh
|
||||||
chmod 400 /root/.ssh/id_rsa
|
cp deploy_key /root/.ssh/id_rsa
|
||||||
cp ssh_config /root/.ssh/config
|
chmod 400 /root/.ssh/id_rsa
|
||||||
|
cp ssh_config /root/.ssh/config
|
||||||
|
fi
|
||||||
|
|
||||||
# System dependencies
|
# System dependencies
|
||||||
apt-get -q update
|
apt-get -q update
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
node ./node_modules/coffee-script/bin/coffee -c ./src
|
if [ $NODE_ENV == 'production' ]; then
|
||||||
rm -rf /root/.ssh/* /build/app/deploy_key /app/deploy_key /build/app/Makefile /app/Makefile /app/src/*.coffee
|
node ./node_modules/coffee-script/bin/coffee -c ./src
|
||||||
npm uninstall coffee-script
|
rm -rf /root/.ssh/* /build/app/deploy_key /app/deploy_key /build/app/Makefile /app/Makefile /app/src/*.coffee
|
||||||
|
npm uninstall coffee-script
|
||||||
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user