Skip to content

Commit

Permalink
Merge branch 'develop' into feature/backup
Browse files Browse the repository at this point in the history
# Conflicts:
#	common/ASC.Data.Backup.Core/EF/BackupsContext.cs
#	common/ASC.Data.Backup.Core/Service/BackupWorker.cs
#	common/services/ASC.Data.Backup/Controllers/BackupController.cs
#	common/services/ASC.Data.Backup/Startup.cs
#	packages/asc-web-common/components/PageLayout/sub-components/section-header.js
#	products/ASC.Files/Client/public/locales/en/OperationsPanel.json
#	products/ASC.Files/Client/public/locales/en/Settings.json
#	products/ASC.Files/Client/public/locales/ru/Settings.json
#	products/ASC.Files/Client/src/components/SimpleFileInput/StyledSimpleFileInput.js
#	products/ASC.Files/Client/src/components/panels/SelectFolderDialog/index.js
#	products/ASC.Files/Client/src/components/panels/SelectFolderInput/StyledSelectFolderInput.js
#	products/ASC.Files/Client/src/components/panels/SelectFolderInput/index.js
#	products/ASC.Files/Client/src/components/panels/StyledPanels.js
#	products/ASC.Files/Client/webpack.config.js
#	web/ASC.Web.Client/public/locales/en/Settings.json
#	web/ASC.Web.Client/public/locales/ru/Settings.json
#	web/ASC.Web.Client/webpack.config.js
  • Loading branch information
TatianaLopaeva committed Feb 7, 2022
2 parents 6b89f94 + e16d758 commit 40d5607
Show file tree
Hide file tree
Showing 3,524 changed files with 85,051 additions and 46,112 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ Logs/
.eslintcache
build/deploy/
/public/debuginfo.md
TestsResults/
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,6 @@
path = products/ASC.Files/Server/DocStore
url = https://github.com/ONLYOFFICE/document-templates
branch = main/community-server
[submodule "common/Tests/Frontend.Translations.Tests/dictionaries"]
path = common/Tests/Frontend.Translations.Tests/dictionaries
url = https://github.com/ONLYOFFICE/dictionaries
Binary file not shown.
Binary file not shown.
Binary file removed .nuget/packages/Microsoft.Graph.Core.1.5.0.2.nupkg
Binary file not shown.
Binary file added .nuget/packages/Microsoft.Graph.Core.1.6.0.nupkg
Binary file not shown.
Binary file removed .nuget/packages/Microsoft.OneDriveSDK.2.0.7.6.nupkg
Binary file not shown.
Binary file not shown.
Binary file removed .nuget/packages/Openstack.net.1.7.9.nupkg
Binary file not shown.
Binary file added .nuget/packages/Openstack.net.1.8.0.nupkg
Binary file not shown.
Binary file removed .nuget/packages/Rackspace.0.2.1.nupkg
Binary file not shown.
Binary file added .nuget/packages/Rackspace.1.0.0.nupkg
Binary file not shown.
Binary file not shown.
Binary file not shown.
45 changes: 43 additions & 2 deletions ASC.Tests.sln
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.30413.136
# Visual Studio Version 17
VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Files.Tests", "products\ASC.Files\Tests\ASC.Files.Tests.csproj", "{EFB99A37-EF25-4A0F-8D7A-786402B1554C}"
EndProject
Expand Down Expand Up @@ -67,6 +67,20 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Core.Common.Tests", "co
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Notify.Textile.Tests", "common\Tests\ASC.Notify.Textile.Tests\ASC.Notify.Textile.Tests.csproj", "{8FAD3D1B-3ADC-470C-9933-CAE1B95A8599}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Webhooks.Core", "common\ASC.Webhooks.Core\ASC.Webhooks.Core.csproj", "{A0475D4F-29B7-490C-85C2-8AFD60118B35}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Webhooks.Tests", "common\Tests\ASC.Webhooks.Tests\ASC.Webhooks.Tests.csproj", "{B48C0E24-EBEB-4AF9-891B-D28BB4A9461E}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Webhooks.Service", "common\services\ASC.Webhooks.Service\ASC.Webhooks.Service.csproj", "{23310CB9-1A14-4ED5-BF81-8BD38277FEFE}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Web.Api.Tests", "common\Tests\ASC.Web.Api.Tests\ASC.Web.Api.Tests.csproj", "{14823E93-C749-4069-9E0A-95E63DE0B254}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Data.Backup.Core", "common\ASC.Data.Backup.Core\ASC.Data.Backup.Core.csproj", "{5E948877-52BD-42B9-95A9-0FF37931D0A5}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Data.Encryption", "common\ASC.Data.Encryption\ASC.Data.Encryption.csproj", "{9E572FE2-8C3C-46B2-A314-532F7198B3EB}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.AuditTrail", "common\services\ASC.AuditTrail\ASC.AuditTrail.csproj", "{B53587B7-58F6-48A9-B122-69BEA3E2572A}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -201,6 +215,33 @@ Global
{8FAD3D1B-3ADC-470C-9933-CAE1B95A8599}.Debug|Any CPU.Build.0 = Debug|Any CPU
{8FAD3D1B-3ADC-470C-9933-CAE1B95A8599}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8FAD3D1B-3ADC-470C-9933-CAE1B95A8599}.Release|Any CPU.Build.0 = Release|Any CPU
{A0475D4F-29B7-490C-85C2-8AFD60118B35}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A0475D4F-29B7-490C-85C2-8AFD60118B35}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A0475D4F-29B7-490C-85C2-8AFD60118B35}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A0475D4F-29B7-490C-85C2-8AFD60118B35}.Release|Any CPU.Build.0 = Release|Any CPU
{B48C0E24-EBEB-4AF9-891B-D28BB4A9461E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B48C0E24-EBEB-4AF9-891B-D28BB4A9461E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B48C0E24-EBEB-4AF9-891B-D28BB4A9461E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B48C0E24-EBEB-4AF9-891B-D28BB4A9461E}.Release|Any CPU.Build.0 = Release|Any CPU
{23310CB9-1A14-4ED5-BF81-8BD38277FEFE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{23310CB9-1A14-4ED5-BF81-8BD38277FEFE}.Debug|Any CPU.Build.0 = Debug|Any CPU
{23310CB9-1A14-4ED5-BF81-8BD38277FEFE}.Release|Any CPU.ActiveCfg = Release|Any CPU
{14823E93-C749-4069-9E0A-95E63DE0B254}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{14823E93-C749-4069-9E0A-95E63DE0B254}.Debug|Any CPU.Build.0 = Debug|Any CPU
{14823E93-C749-4069-9E0A-95E63DE0B254}.Release|Any CPU.ActiveCfg = Release|Any CPU
{14823E93-C749-4069-9E0A-95E63DE0B254}.Release|Any CPU.Build.0 = Release|Any CPU
{5E948877-52BD-42B9-95A9-0FF37931D0A5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5E948877-52BD-42B9-95A9-0FF37931D0A5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5E948877-52BD-42B9-95A9-0FF37931D0A5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5E948877-52BD-42B9-95A9-0FF37931D0A5}.Release|Any CPU.Build.0 = Release|Any CPU
{9E572FE2-8C3C-46B2-A314-532F7198B3EB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9E572FE2-8C3C-46B2-A314-532F7198B3EB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{9E572FE2-8C3C-46B2-A314-532F7198B3EB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9E572FE2-8C3C-46B2-A314-532F7198B3EB}.Release|Any CPU.Build.0 = Release|Any CPU
{B53587B7-58F6-48A9-B122-69BEA3E2572A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B53587B7-58F6-48A9-B122-69BEA3E2572A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B53587B7-58F6-48A9-B122-69BEA3E2572A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B53587B7-58F6-48A9-B122-69BEA3E2572A}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
37 changes: 37 additions & 0 deletions ASC.Tools.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.0.31815.197
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Core.Common", "common\ASC.Core.Common\ASC.Core.Common.csproj", "{A51D0454-4AFA-46DE-89D4-B03D37E1816C}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AutoMigrationCreator", "common\Tools\AutoMigrationCreator\AutoMigrationCreator.csproj", "{D779E2D7-1060-43D3-B8F2-F76A73CCFEBC}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Files.Core", "products\ASC.Files\Core\ASC.Files.Core.csproj", "{B3D98EF4-B9A3-4082-AE78-7CF4C5CF5211}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{A51D0454-4AFA-46DE-89D4-B03D37E1816C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{A51D0454-4AFA-46DE-89D4-B03D37E1816C}.Debug|Any CPU.Build.0 = Debug|Any CPU
{A51D0454-4AFA-46DE-89D4-B03D37E1816C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{A51D0454-4AFA-46DE-89D4-B03D37E1816C}.Release|Any CPU.Build.0 = Release|Any CPU
{D779E2D7-1060-43D3-B8F2-F76A73CCFEBC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D779E2D7-1060-43D3-B8F2-F76A73CCFEBC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D779E2D7-1060-43D3-B8F2-F76A73CCFEBC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D779E2D7-1060-43D3-B8F2-F76A73CCFEBC}.Release|Any CPU.Build.0 = Release|Any CPU
{B3D98EF4-B9A3-4082-AE78-7CF4C5CF5211}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{B3D98EF4-B9A3-4082-AE78-7CF4C5CF5211}.Debug|Any CPU.Build.0 = Debug|Any CPU
{B3D98EF4-B9A3-4082-AE78-7CF4C5CF5211}.Release|Any CPU.ActiveCfg = Release|Any CPU
{B3D98EF4-B9A3-4082-AE78-7CF4C5CF5211}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {3A1E5FB1-22F6-4394-BFF3-8733F4A23003}
EndGlobalSection
EndGlobal
12 changes: 12 additions & 0 deletions ASC.Web.sln
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,10 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Data.Backup.Core", "com
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Data.Backup", "common\services\ASC.Data.Backup\ASC.Data.Backup.csproj", "{027EEE53-7491-48F4-B467-6404D68798A7}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Webhooks.Core", "common\ASC.Webhooks.Core\ASC.Webhooks.Core.csproj", "{760BFF3A-1A67-43A1-A94C-78D11A4BB1E6}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ASC.Webhooks.Service", "common\services\ASC.Webhooks.Service\ASC.Webhooks.Service.csproj", "{DAE2912D-1465-4D60-B1D7-90EE835003E4}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -275,6 +279,14 @@ Global
{027EEE53-7491-48F4-B467-6404D68798A7}.Debug|Any CPU.Build.0 = Debug|Any CPU
{027EEE53-7491-48F4-B467-6404D68798A7}.Release|Any CPU.ActiveCfg = Release|Any CPU
{027EEE53-7491-48F4-B467-6404D68798A7}.Release|Any CPU.Build.0 = Release|Any CPU
{760BFF3A-1A67-43A1-A94C-78D11A4BB1E6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{760BFF3A-1A67-43A1-A94C-78D11A4BB1E6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{760BFF3A-1A67-43A1-A94C-78D11A4BB1E6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{760BFF3A-1A67-43A1-A94C-78D11A4BB1E6}.Release|Any CPU.Build.0 = Release|Any CPU
{DAE2912D-1465-4D60-B1D7-90EE835003E4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DAE2912D-1465-4D60-B1D7-90EE835003E4}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DAE2912D-1465-4D60-B1D7-90EE835003E4}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DAE2912D-1465-4D60-B1D7-90EE835003E4}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
39 changes: 39 additions & 0 deletions ASC.Web.slnf
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"solution": {
"path": "ASC.Web.sln",
"projects": [
"common\\ASC.Api.Core\\ASC.Api.Core.csproj",
"common\\ASC.Common\\ASC.Common.csproj",
"common\\ASC.Core.Common\\ASC.Core.Common.csproj",
"common\\ASC.Data.Backup.Core\\ASC.Data.Backup.Core.csproj",
"common\\ASC.Data.Reassigns\\ASC.Data.Reassigns.csproj",
"common\\ASC.Data.Storage\\ASC.Data.Storage.csproj",
"common\\ASC.FederatedLogin\\ASC.FederatedLogin.csproj",
"common\\ASC.Feed\\ASC.Feed.csproj",
"common\\ASC.IPSecurity\\ASC.IPSecurity.csproj",
"common\\ASC.MessagingSystem\\ASC.MessagingSystem.csproj",
"common\\ASC.Notify.Textile\\ASC.Notify.Textile.csproj",
"common\\ASC.Textile\\ASC.Textile.csproj",
"common\\ASC.VoipService\\ASC.VoipService.csproj",
"common\\ASC.Webhooks.Core\\ASC.Webhooks.Core.csproj",
"common\\services\\ASC.AuditTrail\\ASC.AuditTrail.csproj",
"common\\services\\ASC.ClearEvents\\ASC.ClearEvents.csproj",
"common\\services\\ASC.Data.Backup\\ASC.Data.Backup.csproj",
"common\\services\\ASC.ElasticSearch\\ASC.ElasticSearch.csproj",
"common\\services\\ASC.Feed.Aggregator\\ASC.Feed.Aggregator.csproj",
"common\\services\\ASC.Notify\\ASC.Notify.csproj",
"common\\services\\ASC.Studio.Notify\\ASC.Studio.Notify.csproj",
"common\\services\\ASC.TelegramService\\ASC.TelegramService.csproj",
"common\\services\\ASC.UrlShortener.Svc\\ASC.UrlShortener.Svc.csproj",
"common\\services\\ASC.Webhooks.Service\\ASC.Webhooks.Service.csproj",
"products\\ASC.Files\\Core\\ASC.Files.Core.csproj",
"products\\ASC.Files\\Server\\ASC.Files.csproj",
"products\\ASC.Files\\Service\\ASC.Files.Service.csproj",
"products\\ASC.People\\Server\\ASC.People.csproj",
"web\\ASC.Web.Api\\ASC.Web.Api.csproj",
"web\\ASC.Web.Core\\ASC.Web.Core.csproj",
"web\\ASC.Web.HealthChecks.UI\\ASC.Web.HealthChecks.UI.csproj",
"web\\ASC.Web.Studio\\ASC.Web.Studio.csproj"
]
}
}
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Platform for building your own scalable online office with ONLYOFFICE modules

## Overview
App Server is a platform for building your own online office by connecting ONLYOFFICE modules packed as separate apps.
App Server is a platform for building your own online office by connecting ONLYOFFICE modules packaged as separate apps.

## How to install
[coming soon]
Expand Down Expand Up @@ -35,4 +35,4 @@ Components source code - [https://github.com/ONLYOFFICE/AppComponents](https://g

## User feedback and support

If you have any problems or question about App Server, use the issues section here, in this repository.
If you have any problems or questions about App Server, use the issues section here, in this repository.
8 changes: 4 additions & 4 deletions build/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ pipeline {
}
stage('Backend') {
steps {
sh 'dotnet build -c Release ASC.Web.sln'
sh 'dotnet build -c Release ASC.Web.slnf'
}
}
}
Expand All @@ -28,7 +28,7 @@ pipeline {
}
stage('Backend') {
steps {
bat 'dotnet build -c Release ASC.Web.sln'
bat 'dotnet build -c Release ASC.Web.slnf'
}
}
}
Expand Down Expand Up @@ -62,7 +62,7 @@ pipeline {
}
stage('Files') {
steps {
sh "git submodule update --progress --init -- products/ASC.Files/Server/DocStore && dotnet build ASC.Web.sln && cd ${env.WORKSPACE}/products/ASC.Files/Tests/ && dotnet test ASC.Files.Tests.csproj -r linux-x64 -l \"console;verbosity=detailed\""
sh "git submodule update --progress --init -- products/ASC.Files/Server/DocStore && dotnet build ASC.Web.slnf && cd ${env.WORKSPACE}/products/ASC.Files/Tests/ && dotnet test ASC.Files.Tests.csproj -r linux-x64 -l \"console;verbosity=detailed\""
}
}
}
Expand Down Expand Up @@ -90,7 +90,7 @@ pipeline {
}
stage('Files') {
steps {
bat "git submodule update --progress --init -- products\\ASC.Files\\Server\\DocStore && dotnet build ASC.Web.sln && cd ${env.WORKSPACE}\\products\\ASC.Files\\Tests\\ && dotnet test ASC.Files.Tests.csproj"
bat "git submodule update --progress --init -- products\\ASC.Files\\Server\\DocStore && dotnet build ASC.Web.slnf && cd ${env.WORKSPACE}\\products\\ASC.Files\\Tests\\ && dotnet test ASC.Files.Tests.csproj"
}
}
}
Expand Down
38 changes: 30 additions & 8 deletions build/build.backend.bat
Original file line number Diff line number Diff line change
@@ -1,11 +1,33 @@
PUSHD %~dp0..
dotnet build ASC.Web.sln /fl1 /flp1:LogFile=build/ASC.Web.log;Verbosity=Normal

@echo off

echo Start build backend...
echo.

cd /D "%~dp0"
call runasadmin.bat "%~dpnx0"

if %errorlevel% == 0 (
for /R "build\scripts\" %%f in (*.sh) do (
echo "%%~nxf"
call build\scripts\%%~nxf
)
)
call start\stop.bat nopause
dotnet build ..\asc.web.slnf /fl1 /flp1:logfile=asc.web.log;verbosity=normal
echo.

call start\start.bat nopause

echo install nodejs projects dependencies...
echo.


for /R "scripts\" %%f in (*.bat) do (
echo Run script %%~nxf...
echo.
call scripts\%%~nxf
)

echo.

if "%1"=="nopause" goto end
pause

)

:end
21 changes: 15 additions & 6 deletions build/build.bat
Original file line number Diff line number Diff line change
@@ -1,18 +1,27 @@
@echo off

echo "##########################################################"
echo "######### Start build and deploy #######################"
echo "##########################################################"

echo.

PUSHD %~dp0
call runasadmin.bat "%~dpnx0"
if %errorlevel% == 0 (

call start\stop.bat
if %errorlevel% == 0 (

PUSHD %~dp0..
call start\stop.bat nopause

echo "FRONT-END (for start run command 'yarn start' inside the root folder)"
call build\build.frontend.bat
call build.frontend.bat nopause

echo "BACK-END"
call build\build.backend.bat
call build.backend.bat nopause

call start\start.bat nopause

start /b call build\start\start.bat
echo.

pause
)
4 changes: 3 additions & 1 deletion build/build.frontend.bat
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
PUSHD %~dp0..

REM call yarn wipe
call yarn install
call yarn install

POPD
44 changes: 33 additions & 11 deletions build/build.static.bat
Original file line number Diff line number Diff line change
@@ -1,25 +1,32 @@
PUSHD %~dp0
@echo off

cd /D "%~dp0"
call runasadmin.bat "%~dpnx0"

if %errorlevel% == 0 (
PUSHD %~dp0..

echo "mode=%1"
IF "%2"=="personal" (
echo "mode=%2"
) ELSE (
echo "mode="
)

REM call yarn wipe
call yarn install

REM call yarn build
IF "%1"=="" (
call yarn build
) ELSE (
IF "%2"=="personal" (
call yarn build:personal
) ELSE (
call yarn build
)

REM call yarn wipe
IF "%1"=="" (
call yarn deploy
) ELSE (
IF "%2"=="personal" (
call yarn deploy:personal
) ELSE (
call yarn deploy
)

REM copy nginx configurations to deploy folder
Expand All @@ -40,10 +47,25 @@ powershell -Command "(gc build\deploy\nginx\sites-enabled\onlyoffice-projects.co
powershell -Command "(gc build\deploy\nginx\sites-enabled\onlyoffice-studio.conf) -replace 'ROOTPATH', '%~dp0deploy\studio\client' -replace '\\', '/' | Out-File -encoding ASCII build\deploy\nginx\sites-enabled\onlyoffice-studio.conf"

REM restart nginx
call sc stop nginx
echo service nginx stop
call sc stop nginx > nul

REM sleep 5 seconds
call ping 127.0.0.1 -n 6 > nul

call sc start nginx
)
echo service nginx start
call sc start nginx > nul

if NOT %errorlevel% == 0 (
echo Couldn't restarte Onlyoffice%%~nf service
)

)

echo.

POPD

if "%1"=="nopause" goto start
pause
:start
Loading

0 comments on commit 40d5607

Please sign in to comment.