Add new shell scripts useful for development (#18905)

* Create run-dev.sh and deploy.sh for more applications

* Remove wrong line
This commit is contained in:
Gustavo Trott 2023-10-06 15:12:16 -03:00 committed by GitHub
parent 35f25f8b3d
commit de514dcb75
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 83 additions and 4 deletions

View File

@ -0,0 +1,21 @@
#!/usr/bin/env bash
cd "$(dirname "$0")"
for var in "$@"
do
if [[ $var == --reset ]] ; then
echo "Performing a full reset..."
rm -rf node_modules
fi
done
if [ ! -d ./node_modules ] ; then
npm install --production
fi
sudo cp -r ./* /usr/local/bigbluebutton/bbb-export-annotations
sudo systemctl restart bbb-export-annotations
echo ''
echo ''
echo '----------------'
echo 'bbb-export-annotations updated'

View File

@ -0,0 +1,17 @@
#!/usr/bin/env bash
cd "$(dirname "$0")"
for var in "$@"
do
if [[ $var == --reset ]] ; then
echo "Performing a full reset..."
rm -rf node_modules
fi
done
if [ ! -d ./node_modules ] ; then
npm install
fi
sudo systemctl stop bbb-export-annotations
npm start

View File

@ -0,0 +1,24 @@
#!/usr/bin/env bash
cd "$(dirname "$0")"
for var in "$@"
do
if [[ $var == --reset ]] ; then
echo "Performing a full reset..."
rm -rf node_modules
fi
done
if [ ! -d ./node_modules ] ; then
npm ci --no-progress
fi
npm run build
mv -f dist/index.js dist/bbb-graphql-actions-adapter-server.js
sudo cp -rf dist/* /usr/local/bigbluebutton/bbb-graphql-actions-adapter-server/
sudo systemctl restart bbb-graphql-actions-adapter-server
echo ''
echo ''
echo '----------------'
echo 'bbb-graphql-actions-adapter-server updated'

View File

@ -0,0 +1,17 @@
#!/usr/bin/env bash
cd "$(dirname "$0")"
for var in "$@"
do
if [[ $var == --reset ]] ; then
echo "Performing a full reset..."
rm -rf node_modules
fi
done
if [ ! -d ./node_modules ] ; then
npm install
fi
sudo systemctl stop bbb-graphql-actions-adapter-server
npm start

View File

@ -8,11 +8,11 @@ cd "$(dirname "$0")"
#Install Go
#sudo apt install golang -y
GO_VERSION=1.20.6
GO_VERSION=1.20.8
wget --no-verbose https://dl.google.com/go/go${GO_VERSION}.linux-amd64.tar.gz \
&& tar -xzf go${GO_VERSION}.linux-amd64.tar.gz \
&& ln -s ${PWD}/go/bin/go /usr/bin/go \
&& rm go${GO_VERSION}.linux-amd64.tar.gz
&& tar -C /usr/local -xzf go${GO_VERSION}.linux-amd64.tar.gz \
&& rm go${GO_VERSION}.linux-amd64.tar.gz \
&& ln -sf /usr/local/go/bin/go /usr/bin/go
go version