Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,301,020
Community Members
 
Community Events
165
Community Groups

bamboo build still in progress windows batch script completed..

Dears

Bamboo server not complete build ans still in progress even the script task to run the batch script completed.Please advice

 

this is my script:

@echo off
REM ----- [ REQUEST ADMIN PRIVILEDGES :: DO NOT MODIFY THIS SECTION ] -----

:: BatchGotAdmin
::-------------------------------------
REM --> Check for permissions
>nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system"

REM --> If error flag set, we do not have admin.
if '%errorlevel%' NEQ '0' (
echo Requesting administrative privileges...
goto UACPrompt
) else ( goto gotAdmin )

:UACPrompt
echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs"
set params = %*:"="
echo UAC.ShellExecute "cmd.exe", "/c %~s0 %params%", "", "runas", 1 >> "%temp%\getadmin.vbs"

"%temp%\getadmin.vbs"
del "%temp%\getadmin.vbs"
exit /B

:gotAdmin
pushd "%CD%"
CD /D "%~dp0"
::--------------------------------------
::ENTER YOUR CODE BELOW:

NET SESSION >nul 2>&1

IF %ERRORLEVEL% EQU 0 (
ECHO Administrator PRIVILEGES Detected!
ECHO ===========================================================
) ELSE (
echo WARNING : Administrator Privileges NOT Detected!
)

REM ----- [ REQUEST ADMIN PRIVILEDGES :: DO NOT MODIFY THIS SECTION ] -----
REM ----- [ ACTUAL CODE STARTS FROM HERE ] -----

@echo Installing [npm modules for tests]
@echo ===========================================================
call npm install

@echo Installing [selenium-standalone server]
@echo ===========================================================
call npm install selenium-standalone@latest -g

@echo Installing [gecko driver]
@echo ===========================================================
call npm install geckodriver -g

@echo Installing [chrome driver]
@echo ===========================================================
call selenium-standalone install --drivers.chrome.version=2.43 -g --drivers.chrome.baseURL=https://chromedriver.storage.googleapis.com

@echo Starting [Selenium-standalone server]
@echo ===========================================================
call selenium-standalone start

call exit 0;

 

 

1 comment

Jimmy Seddon Community Leader Apr 22, 2020

Hi @directfn_devops,

I have seem so signals get crossed before.  Is this the only time that it has happened or do you see this consistently every time you run this build.

What tasks happen after this one has finished, it might be worth looking at what comes next to see if there is something that is hanging starting the next task.

I hope that helps!

-Jimmy

Hi Jimmy

This is happening every time from this command "call selenium-standalone start ".. is there any way to start selenium in background in windows.

 

Regards

Raveendra

Jimmy Seddon Community Leader Apr 22, 2020

A little outside my realm of expertise, but a quick search on Google suggests that you should be able to pass a '--headless'  argument to the chrome driver options, and that should run selenium-standalone as a background task.

I hope that helps!

-Jimmy

Comment

Log in or Sign up to comment
TAGS
Community showcase
Published in Bamboo

Bamboo Data Center on Kubernetes

Hi, If you are running self-managed environments and looking to adopt modern infrastructure, Bamboo Data Center can now be deployed in a Kubernetes cluster. By leveraging Kubernetes, you can easily...

972 views 3 8
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you