-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated build scripts for latest version
- Loading branch information
1 parent
866a4e4
commit 2d5c9d5
Showing
2 changed files
with
50 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,22 @@ | ||
#!/bin/bash | ||
CONTAINER=onlyoffice-document-server | ||
LOCATION=/var/www/onlyoffice/documentserver/sdkjs | ||
LOCATION=/var/www/onlyoffice/documentserver/ | ||
|
||
cd build | ||
grunt --level=WHITESPACE_ONLY --formatting=PRETTY_PRINT | ||
cd ../deploy/sdkjs/ | ||
sudo docker exec $CONTAINER /bin/bash -c "cd $LOCATION && find . -type f -name '*.gz' -delete" | ||
sudo docker cp word/sdk-all.js $CONTAINER:$LOCATION/word | ||
sudo docker cp word/sdk-all-min.js $CONTAINER:$LOCATION/word | ||
sudo docker cp slide/sdk-all.js $CONTAINER:$LOCATION/slide | ||
sudo docker cp slide/sdk-all-min.js $CONTAINER:$LOCATION/slide | ||
sudo docker cp cell/sdk-all.js $CONTAINER:$LOCATION/cell | ||
sudo docker cp cell/sdk-all-min.js $CONTAINER:$LOCATION/cell | ||
sudo docker cp common $CONTAINER:$LOCATION | ||
if [ -z "$NOBUILD" ] | ||
then | ||
if [ -z "$PRODUCTION" ] | ||
then | ||
grunt --level=WHITESPACE_ONLY --formatting=PRETTY_PRINT | ||
else | ||
echo "Production build" | ||
grunt --level=ADVANCED | ||
fi | ||
fi | ||
|
||
cd ../deploy/ | ||
# sudo docker exec onlyoffice-document-server /bin/bash -c "sudo rm -rf $LOCATION/sdkjs" | ||
sudo docker cp sdkjs $CONTAINER:$LOCATION | ||
|
||
# restart document-server | ||
sudo docker exec onlyoffice-document-server supervisorctl restart all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,33 @@ | ||
#!/bin/bash | ||
KEY=~/.ssh/ec2.pem | ||
[email protected]:/var/www/onlyoffice/documentserver/ | ||
export PRODUCT_VERSION="15.2.0" | ||
export BUILD_NUMBER="111" | ||
cd build | ||
grunt --level=ADVANCED | ||
cd .. | ||
cd deploy/ | ||
scp -i $KEY -r sdkjs $SERVER | ||
LOCATION=/var/www/onlyoffice/documentserver | ||
if [ -z "$DEV" ] | ||
then | ||
[email protected] | ||
else | ||
[email protected] | ||
fi | ||
|
||
echo "Server: $SERVER" | ||
|
||
if [ -z "$NOBUILD" ] | ||
then | ||
echo "-- Building" | ||
export PRODUCT_VERSION="15.5.0" | ||
export BUILD_NUMBER="111" | ||
export PUBLISHER_URL="https://www.zegenie.com" | ||
cd build | ||
grunt --level=ADVANCED | ||
cd .. | ||
fi | ||
|
||
if [ -z "$NOPUSH" ] | ||
then | ||
echo "-- Pushing to server" | ||
cd deploy/ | ||
rm -f sdkjs.tgz > /dev/null | ||
tar cz sdkjs.tgz sdkjs | ||
scp -i $KEY sdkjs.tgz $SERVER:$LOCATION | ||
ssh -i $KEY $SERVER "cd $LOCATION && sudo chown ubuntu:ubuntu -R sdkjs && tar xvf sdkjs.tgz" | ||
rm -f sdkjs.tgz > /dev/null | ||
fi |