• Our product teams collect and evaluate feedback from a number of different sources. To learn more about how we use customer feedback in the planning process, check out our new feature policy.

      It's currently not possible to trigger a deployment project from a stage of a plan. Deployment projects can be triggered upon completion of a plan but if, for example, there is a plan with two stages when the second stage is manual, there is no way to trigger the deployment when the second stage completes.

      One solution can be breaking the stages into two different plans and passing artifacts to the second plan, or setting it as a child plan of the first plan if the manual run can be converted into an automated process but this is not the best or easiest solution.

            [BAM-13501] REST API for deployments

            Plan runners add on adds task to deploy or rollback releases as well as REST API
            https://marketplace.atlassian.com/plugins/com.mdb.plugins.planrunners/server/overview
            Hope this helps.

            Bhagyashree added a comment - Plan runners add on adds task to deploy or rollback releases as well as REST API https://marketplace.atlassian.com/plugins/com.mdb.plugins.planrunners/server/overview Hope this helps.

            Alexey Chystoprudov added a comment - operations67 , have you seen this page with some details about this API calls? https://developer.atlassian.com/display/BAMBOODEV/REST+API+deployment+triggers+for+Bamboo

            Nabru S added a comment -

            Ok, it was my mistake....

            it's working fine with Powershell now (without a dedicated JSON body )

            function global:new-BambooDeployment
            {
              
                $url = "http://bamboo/rest/api/latest/queue/deployment?environmentId=1234&versionId=5678"
                
             Invoke-RestMethod -Uri $url -Headers $Headers -Method post -ContentType "application/json"
            }
            

            Nabru S added a comment - Ok, it was my mistake.... it's working fine with Powershell now (without a dedicated JSON body ) function global: new -BambooDeployment { $url = "http: //bamboo/ rest /api/latest/queue/deployment?environmentId=1234&versionId=5678" Invoke-RestMethod -Uri $url -Headers $Headers -Method post -ContentType "application/json" }

            Nabru S added a comment -

            We are running Bamboo Version 5.12.

            I tried to trigger a deployment via

            /queue/deployment?expand

            How does it work correctly ? I use already a lot of REST API calls but this is not working.
            I found out that I have to user -Content application/x-www-form-urlencoded to perform a get.

            So how to perform a post correctly. I'm using Basic auth.

            Nabru S added a comment - We are running Bamboo Version 5.12. I tried to trigger a deployment via /queue/deployment?expand How does it work correctly ? I use already a lot of REST API calls but this is not working. I found out that I have to user -Content application/x-www-form-urlencoded to perform a get . So how to perform a post correctly. I'm using Basic auth.

            Was the intent of this ticket to implement only an API to trigger deployments? If so, the title is a little misleading and it is very unfortunate that numerous tickets have been closed as 'duplicate' that were requesting CRUD operations for deployment projects and environments.

            It would be invaluable if there were an API that allowed us to create environments, set permissions and add tasks.

            Bryan Custer added a comment - Was the intent of this ticket to implement only an API to trigger deployments? If so, the title is a little misleading and it is very unfortunate that numerous tickets have been closed as 'duplicate' that were requesting CRUD operations for deployment projects and environments. It would be invaluable if there were an API that allowed us to create environments, set permissions and add tasks.

            Note: You only need releaseTypeOption environmentId and promoteVersion in the request body - versionName, planKey, buildNumber and altToken are optional!

            Deleted Account (Inactive) added a comment - Note: You only need releaseTypeOption environmentId and promoteVersion in the request body - versionName , planKey , buildNumber and altToken are optional!

            Edit

            My code snippet above is was wrong..... Corrected code below:

            import java.io.*;
            import java.net.*;
            import org.apache.commons.codec.binary.Base64;
            
            // Bamboo deployment data
            String environmentId = "";
            String versionName   = "";
            String planKey       = "";
            String buildNumber   = "";
            String altToken      = "";
            
            // Application base URL
            String baseURL = "http://bamboo";
            System.out.println("Base URL : " + baseURL);
            
            // Basic authentication
            String authString = "user:pass".getBytes().encodeBase64().toString();
            System.out.println("Auth String : " + authString);
            
            // Resource
            String path = "/deploy/executeManualDeployment.action";
            System.out.println("Resource : " + path);
            
            // Request method
            String requestMethod = "POST";
            
            // Escape the double quotes in json string
            String payload = "environmentId="+environmentId+"&newReleaseBuildResult="+planKey+"-"+buildNumber+"&versionName="+versionName+"&releaseTypeOption=PROMOTE&promoteVersion="+versionName+"&save=Start+deployment&atl_token="+altToken;
            System.out.println("POST Data : " + payload);
            
            try {
                // Target URL of the resource to request
                URL url = new URL(baseURL + path);
            
                // A new connection is opened by calling the openConnection method of
                // the protocol handler for this URL.
                // 1. This is the point where the connection is opened.
                HttpURLConnection connection = (HttpURLConnection) url.openConnection();
                // set connection output to true
                connection.setDoOutput(true);
                // Set request method
                connection.setRequestMethod(requestMethod);
            
                // Declare content type and authentication
                connection.setRequestProperty("Authorization", "Basic " + authString);
                connection.setRequestProperty("Content-Type", "application/x-www-form-urlencoded");
            
                // 2. This is the point where you'll know if the connection was
                // successfully established. If an I/O error occurs while creating
                // the output stream, you'll see an IOException.
                OutputStreamWriter writer = new OutputStreamWriter(connection.getOutputStream());
            
                // 3. Sending the data is conducted here. We established the
                // connection with getOutputStream
                writer.write(payload);
            
                // Closes this output stream and releases any system resources
                // associated with this stream. At this point, we've sent all the
                // data. Only the outputStream is closed at this point, not the
                // actual connection
                writer.close();
            
                // If there is a response code AND that response code is 200 OK, do
                // stuff in the first if block
                if (connection.getResponseCode() == HttpURLConnection.HTTP_OK) {
                    // OK
                    System.out.println("Method : " + connection.getRequestMethod() + " - Successful!");
                    // Otherwise, if any other status code is returned, or no status
                    // code is returned, do stuff in the else block
                    connection.disconnect();
                } else {
                    // Server returned HTTP error code.
                    System.out.println("Method : " + connection.getRequestMethod());
                    System.out.println("Response Code : " + connection.getResponseCode());
                    System.out.println("Response Message : " + connection.getResponseMessage());
                    connection.disconnect();
                }
            } catch (MalformedURLException e) {
                System.out.println("MalformedURLException : " + e);
            } catch (IOException e) {
                System.out.println("IOException : " + e);
            }
            

            Deleted Account (Inactive) added a comment - Edit My code snippet above is was wrong..... Corrected code below: import java.io.*; import java.net.*; import org.apache.commons.codec.binary.Base64; // Bamboo deployment data String environmentId = ""; String versionName = ""; String planKey = ""; String buildNumber = ""; String altToken = ""; // Application base URL String baseURL = "http: //bamboo" ; System .out.println( "Base URL : " + baseURL); // Basic authentication String authString = "user:pass" .getBytes().encodeBase64().toString(); System .out.println( "Auth String : " + authString); // Resource String path = "/deploy/executeManualDeployment.action" ; System .out.println( "Resource : " + path); // Request method String requestMethod = "POST" ; // Escape the double quotes in json string String payload = "environmentId=" +environmentId+ "&newReleaseBuildResult=" +planKey+ "-" +buildNumber+ "&versionName=" +versionName+ "&releaseTypeOption=PROMOTE&promoteVersion=" +versionName+ "&save=Start+deployment&atl_token=" +altToken; System .out.println( "POST Data : " + payload); try { // Target URL of the resource to request URL url = new URL(baseURL + path); // A new connection is opened by calling the openConnection method of // the protocol handler for this URL. // 1. This is the point where the connection is opened. HttpURLConnection connection = (HttpURLConnection) url.openConnection(); // set connection output to true connection.setDoOutput( true ); // Set request method connection.setRequestMethod(requestMethod); // Declare content type and authentication connection.setRequestProperty( "Authorization" , "Basic " + authString); connection.setRequestProperty( "Content-Type" , "application/x-www-form-urlencoded" ); // 2. This is the point where you'll know if the connection was // successfully established. If an I/O error occurs while creating // the output stream, you'll see an IOException. OutputStreamWriter writer = new OutputStreamWriter(connection.getOutputStream()); // 3. Sending the data is conducted here. We established the // connection with getOutputStream writer.write(payload); // Closes this output stream and releases any system resources // associated with this stream. At this point, we've sent all the // data. Only the outputStream is closed at this point, not the // actual connection writer.close(); // If there is a response code AND that response code is 200 OK, do // stuff in the first if block if (connection.getResponseCode() == HttpURLConnection.HTTP_OK) { // OK System .out.println( "Method : " + connection.getRequestMethod() + " - Successful!" ); // Otherwise, if any other status code is returned, or no status // code is returned, do stuff in the else block connection.disconnect(); } else { // Server returned HTTP error code. System .out.println( "Method : " + connection.getRequestMethod()); System .out.println( "Response Code : " + connection.getResponseCode()); System .out.println( "Response Message : " + connection.getResponseMessage()); connection.disconnect(); } } catch (MalformedURLException e) { System .out.println( "MalformedURLException : " + e); } catch (IOException e) { System .out.println( "IOException : " + e); }

            Discovered that you can trigger a deployment a HTTP POST request... I copied the deployment action as a cURL command in the Chrome dev tools Network tab - see Rafael Sperafico's answer to How to trigger Bamboo deployment using API?. I stripped all the headers except "Content-Type" and passed in basic authentication:

            curl -D- -u user:pass -X POST 'http://bamboo/deploy/executeManualDeployment.action' -H 'Content-Type: application/x-www-form-urlencoded' --data 'environmentId=[ENVIRONMENT-ID]&newReleaseBuildResult=[PLAN-KEY]-[BUILD-NUMBER]&versionName=[RELEASE-NAME/NUMBER]&releaseTypeOption=PROMOTE&promoteVersion=[RELEASE-NAME/NUMBER]&save=Start+deployment&atl_token=[PASTE-YOUR-ALT_TOKEN-HERE]'
            

            You will need to follow the steps in How to trigger Bamboo deployment using API? to get your atl_token value for the cURL command. I'm currently running a JIRA Workflow custom script post function, allowing my developers to deploy from their JIRA issues:

            import java.io.*;
            import java.net.*;
            import org.apache.commons.codec.binary.Base64;
            
            // Bamboo deployment data
            String environmentId = "[ENVIRONMENT-ID]";
            String versionName   = "[RELEASE-NAME/NUMBER]";
            String planKey       = "[PLAN-KEY]";
            String buildNumber   = "[BUILD-NUMBER]";
            String altToken         = "[PASTE-YOUR-ALT_TOKEN-HERE]";
            
            // Application base URL
            String baseURL = "http://bamboo";
            System.out.println("Base URL : " + baseURL);
            
            // Basic authentication
            String authString = "user:pass".getBytes().encodeBase64().toString();
            System.out.println("Auth String : " + authString);
            
            // Resource
            String path = "/deploy/executeManualDeployment.action";
            System.out.println("Resource : " + path);
            
            // Escape the double quotes in json string
            String payload = "environmentId="+environmentId+"&newReleaseBuildResult="+planKey+"-"+buildNumber+"&versionName="+versionName+"&releaseTypeOption=PROMOTE&promoteVersion="+versionName+"&save=Start+deployment&atl_token="+altToken;
            System.out.println("POST Data : " + payload);
            
            try {
                // Target URL of the resource to request
                URL url = new URL(baseURL + path);
            
                // A new connection is opened by calling the openConnection method of
                // the protocol handler for this URL.
                // 1. This is the point where the connection is opened.
                HttpURLConnection connection = (HttpURLConnection) url.openConnection();
                // set connection output to true
                connection.setDoOutput(true);
            
                // Declare content type and authentication
                connection.setRequestProperty("Content-Type", "application/x-www-form-urlencoded");
                connection.setRequestProperty("Authorization", "Basic " + authString);
            
                // 2. This is the point where you'll know if the connection was
                // successfully established. If an I/O error occurs while creating
                // the output stream, you'll see an IOException.
                OutputStreamWriter writer = new OutputStreamWriter(connection.getOutputStream());
            
                // 3. Sending the data is conducted here. We established the
                // connection with getOutputStream
                writer.write(payload);
            
                // Closes this output stream and releases any system resources
                // associated with this stream. At this point, we've sent all the
                // data. Only the outputStream is closed at this point, not the
                // actual connection
                writer.close();
            
                // If there is a response code AND that response code is 200 OK, do
                // stuff in the first if block
                if (connection.getResponseCode() == HttpURLConnection.HTTP_OK) {
                    // OK
                    System.out.println("Method : " + connection.getRequestMethod() + " - Successful!");
                    // Otherwise, if any other status code is returned, or no status
                    // code is returned, do stuff in the else block
                    connection.disconnect();
                } else {
                    // Server returned HTTP error code.
                    System.out.println("Method : " + connection.getRequestMethod());
                    System.out.println("Response Code : " + connection.getResponseCode());
                    System.out.println("Response Message : " + connection.getResponseMessage());
                    connection.disconnect();
                }
            } catch (MalformedURLException e) {
                System.out.println("MalformedURLException : " + e);
            } catch (IOException e) {
                System.out.println("IOException : " + e);
            }
            

            I'll leave you smart people to it

            P.S. You could use a build plan to download and deploy your artifact instead. Build plans have better REST API support.

            Deleted Account (Inactive) added a comment - Discovered that you can trigger a deployment a HTTP POST request... I copied the deployment action as a cURL command in the Chrome dev tools Network tab - see Rafael Sperafico's answer to How to trigger Bamboo deployment using API? . I stripped all the headers except "Content-Type" and passed in basic authentication: curl -D- -u user:pass -X POST 'http: //bamboo/deploy/executeManualDeployment.action' -H 'Content-Type: application/x-www-form-urlencoded' --data 'environmentId=[ENVIRONMENT-ID]&newReleaseBuildResult=[PLAN-KEY]-[BUILD-NUMBER]&versionName=[RELEASE-NAME/NUMBER]&releaseTypeOption=PROMOTE&promoteVersion=[RELEASE-NAME/NUMBER]&save=Start+deployment&atl_token=[PASTE-YOUR-ALT_TOKEN-HERE]' You will need to follow the steps in How to trigger Bamboo deployment using API? to get your atl_token value for the cURL command. I'm currently running a JIRA Workflow custom script post function, allowing my developers to deploy from their JIRA issues: import java.io.*; import java.net.*; import org.apache.commons.codec.binary.Base64; // Bamboo deployment data String environmentId = "[ENVIRONMENT-ID]" ; String versionName = "[RELEASE-NAME/NUMBER]" ; String planKey = "[PLAN-KEY]" ; String buildNumber = "[BUILD-NUMBER]" ; String altToken = "[PASTE-YOUR-ALT_TOKEN-HERE]" ; // Application base URL String baseURL = "http: //bamboo" ; System .out.println( "Base URL : " + baseURL); // Basic authentication String authString = "user:pass" .getBytes().encodeBase64().toString(); System .out.println( "Auth String : " + authString); // Resource String path = "/deploy/executeManualDeployment.action" ; System .out.println( "Resource : " + path); // Escape the double quotes in json string String payload = "environmentId=" +environmentId+ "&newReleaseBuildResult=" +planKey+ "-" +buildNumber+ "&versionName=" +versionName+ "&releaseTypeOption=PROMOTE&promoteVersion=" +versionName+ "&save=Start+deployment&atl_token=" +altToken; System .out.println( "POST Data : " + payload); try { // Target URL of the resource to request URL url = new URL(baseURL + path); // A new connection is opened by calling the openConnection method of // the protocol handler for this URL. // 1. This is the point where the connection is opened. HttpURLConnection connection = (HttpURLConnection) url.openConnection(); // set connection output to true connection.setDoOutput( true ); // Declare content type and authentication connection.setRequestProperty( "Content-Type" , "application/x-www-form-urlencoded" ); connection.setRequestProperty( "Authorization" , "Basic " + authString); // 2. This is the point where you'll know if the connection was // successfully established. If an I/O error occurs while creating // the output stream, you'll see an IOException. OutputStreamWriter writer = new OutputStreamWriter(connection.getOutputStream()); // 3. Sending the data is conducted here. We established the // connection with getOutputStream writer.write(payload); // Closes this output stream and releases any system resources // associated with this stream. At this point, we've sent all the // data. Only the outputStream is closed at this point, not the // actual connection writer.close(); // If there is a response code AND that response code is 200 OK, do // stuff in the first if block if (connection.getResponseCode() == HttpURLConnection.HTTP_OK) { // OK System .out.println( "Method : " + connection.getRequestMethod() + " - Successful!" ); // Otherwise, if any other status code is returned, or no status // code is returned, do stuff in the else block connection.disconnect(); } else { // Server returned HTTP error code. System .out.println( "Method : " + connection.getRequestMethod()); System .out.println( "Response Code : " + connection.getResponseCode()); System .out.println( "Response Message : " + connection.getResponseMessage()); connection.disconnect(); } } catch (MalformedURLException e) { System .out.println( "MalformedURLException : " + e); } catch (IOException e) { System .out.println( "IOException : " + e); } I'll leave you smart people to it P.S. You could use a build plan to download and deploy your artifact instead. Build plans have better REST API support.

            We've tried that plugin but it keeps trying to pause the entire server whenever you create a template plan or update a plan that is derived from a template. We can't have the entire server paused multiple times a day.

            Oliver Eikenberry added a comment - We've tried that plugin but it keeps trying to pause the entire server whenever you create a template plan or update a plan that is derived from a template. We can't have the entire server paused multiple times a day.

            boris_alyurov_prcm added a comment - Oliver, Checkout this add-on for build templates: https://github.com/valenssoftware/bamboo-templatedplans-plugin https://marketplace.atlassian.com/plugins/org.valens.bamboo-templatedplans-plugin/server/overview

            I'm actually in research and design mode to create a Deploy API plugin within my company. It is ridiculous that Atlasssian has not provided this support yet and that they don't have templates for build and deployment.

            Oliver Eikenberry added a comment - I'm actually in research and design mode to create a Deploy API plugin within my company. It is ridiculous that Atlasssian has not provided this support yet and that they don't have templates for build and deployment.

            When large enterprises are reduced to Selenium-like triggering and hacking the Bamboo DB to get stuff done (GSD), it's time to provide some restful solutions. At this point I'm tempted to write the Deploy API plugin within our company and just publish.

            Matthew Korich added a comment - When large enterprises are reduced to Selenium-like triggering and hacking the Bamboo DB to get stuff done (GSD), it's time to provide some restful solutions. At this point I'm tempted to write the Deploy API plugin within our company and just publish.

            I concur with most of the comments. Really strange that Atlassian did not expose an API to kick off a deployment. We had to create our own custom solution that works well (alas, it depends on deciphering info in Bamboo database). Thanks to previous posters for giving us hints and inspiring us.

            Here are some details on how we trigger deployments in Bamboo (sorry using C#, but Java is very similar):

            • Each release in Bamboo has a unique id (e.g. it tells you what the release name/project it corresponds to). You can find out what the release id is by clicking on a release in Bamboo and looking at versionId parameter on the URL (example: http://myBamboo/deploy/viewDeploymentVersion.action?versionId=123)
            • Bamboo deployment URL is of the form
              http://myBamboo/deploy/selectVersionForExecute.action?environmentId={0}&versionId={1}
              • You can substitute release version id and environment id and use a headless browser to kick it off (we use NHtmlUnit for C#, in Java world it's HtmlUnit). Code snippets are below.
            • When you kick off a deployment, Bamboo gives you a deploymentResultId. This allows you to monitor the status of your deployment by checking Bamboo database (again this is not exposed, so had to improvise here).

            Here are a few snippets to help people (removed error handling to condense code ):

            0) Constants :

            public const string LoginFormName = "loginForm";
            public const string LoginInputFieldUser = "os_username";
            public const string LoginInputFieldPassword = "os_password";
            public const string LoginInputCheckBoxRememberMe = "os_cookie";
            public const string LoginFormButton = "save";
            public const string DeployFormName = "executeManualDeployment";
            public const string DeployFormDeployButton = "save";
            public const string DeploymnetPageKeywordMatch = "Deployment:";
            public const string LoginPagekeywordMatch = "Build Dashboard";        
            

            1) Login to Bamboo (make sure to add error checking):

            WebClient = new WebClient(BrowserVersion.CHROME); //this is using NHtmlUnit 2.15, there is a Nuget package
            WebClient.Options.JavaScriptEnabled = false;
            WebClient.Options.ActiveXNative = false;
            WebClient.Options.CssEnabled = false;
            ..
            HtmlPage page = WebClient.GetHtmlPage(Constants.BambooLoginPageUrl);
            HtmlForm form = page.GetFormByName(Constants.LoginFormName);
            var user = form.GetInputByName(Constants.LoginInputFieldUser) as HtmlTextInput;
            var pass = form.GetInputByName(Constants.LoginInputFieldPassword) as HtmlPasswordInput;
            var rememberLogin = form.GetInputByName(Constants.LoginInputCheckBoxRememberMe) as HtmlCheckBoxInput;
            user.SetValueAttribute(...);
            pass.SetValueAttribute(...);
            rememberLogin.SetChecked(true);
            var submitButton = page.GetElementByName(Constants.LoginFormButton) as HtmlSubmitInput;
            var nextpage = submitButton.Click() as HtmlPage;
            

            2) RunDeploymentUrl (again removed error checking):

            public static long RunDeploymentUrl(string url) {
            ..
            long deploymentResultId = Constants.DeploymentResultIdUnknown;
            var page = WebClient.GetHtmlPage(url);
            var form = page.GetFormByName(Constants.DeployFormName);
            ..
            HtmlSubmitInput submitButton = null;
            //use try-catch, can get errors with this line form.GetByXPath("//div[@class='aui-message error']/p/text()").FirstOrDefault().ToString();
            submitButton = page.GetElementByName(Constants.DeployFormDeployButton) as HtmlSubmitInput;
            var nextpage = submitButton.Click() as HtmlPage;
            //add validation for nextpage.TitleText.Contains this can show issues with triggering the deployment, e.g. already in progress etc
            
            var query=HttpUtility.ParseQueryString(nextpage.Url.Query);
            var paramExtract=Int64.TryParse(query.Get("deploymentResultId"), out deploymentResultId);
            ..
            return deploymentResultId;
            }
            

            3) You can get information about Bamboo deployment or its status using these SQL snippets (Atlassian, please expose it via WebAPI!) :

            --get info about a deployment project given a versionId
            SELECT dv.[NAME] as ReleaseName,	dp.NAME as ProjectName,	DEPLOYMENT_VERSION_ID as DeploymentVersionId,	dv.PROJECT_ID as PlanId,	dp.PLAN_KEY as PlanKey	
            	FROM [dbo].[DEPLOYMENT_VERSION] dv
            	inner join  [dbo].[DEPLOYMENT_PROJECT] dp
            	on dp.[DEPLOYMENT_PROJECT_ID]=dv.[PROJECT_ID]
            	where DEPLOYMENT_VERSION_ID= @versionId
            
            --figure out what the prod environment is for a given Plan (we use Bamboo's Requirement task to mark environment as production)
            select dp.DEPLOYMENT_PROJECT_ID as PlanId,
            			 dp.PLAN_KEY as PlanKey,
            			 dp.NAME as PlanName,	   
            			 de.NAME as Name,
            		 de.ENVIRONMENT_ID as Id
            from 	 dbo.DEPLOYMENT_ENVIRONMENT de       
            			 join dbo.DEPLOYMENT_PROJECT dp on dp.DEPLOYMENT_PROJECT_ID = de.[PACKAGE_DEFINITION_ID]
            where	 
            			 de.XML_DEFINITION_DATA like '%Permission.Deploy.Prod%'
            		 and DEPLOYMENT_PROJECT_ID= @PlanI
            
            --get deployment status,
            -- Life Cycle is Unknown, NotBuilt, InProgress, Queued, Finished
            -- If LifeCycle is Finished, then can check State to see the status (either Unknown, Failed,Successful)
            
            select DEPLOYMENT_RESULT_ID as DeploymentResultId, DEPLOYMENT_STATE as StateString, LIFE_CYCLE_STATE as LifeCycleString, STARTED_DATE as StartedOn, EXECUTED_DATE as ExecutedOn, FINISHED_DATE as FinishedOn, VERSION_ID as DeploymentVersionId, 
            ENVIRONMENT_ID as EnvironmentId 
            from dbo.DEPLOYMENT_RESULT 
            where DEPLOYMENT_RESULT_ID=@deploymentResultId
            

            boris_alyurov_prcm added a comment - I concur with most of the comments. Really strange that Atlassian did not expose an API to kick off a deployment. We had to create our own custom solution that works well (alas, it depends on deciphering info in Bamboo database). Thanks to previous posters for giving us hints and inspiring us. Here are some details on how we trigger deployments in Bamboo (sorry using C#, but Java is very similar): Each release in Bamboo has a unique id (e.g. it tells you what the release name/project it corresponds to). You can find out what the release id is by clicking on a release in Bamboo and looking at versionId parameter on the URL (example: http://myBamboo/deploy/viewDeploymentVersion.action?versionId=123 ) Bamboo deployment URL is of the form http://myBamboo/deploy/selectVersionForExecute.action?environmentId={0}&versionId={1} You can substitute release version id and environment id and use a headless browser to kick it off (we use NHtmlUnit for C#, in Java world it's HtmlUnit). Code snippets are below. When you kick off a deployment, Bamboo gives you a deploymentResultId. This allows you to monitor the status of your deployment by checking Bamboo database (again this is not exposed, so had to improvise here). Here are a few snippets to help people (removed error handling to condense code ): 0) Constants : public const string LoginFormName = "loginForm" ; public const string LoginInputFieldUser = "os_username" ; public const string LoginInputFieldPassword = "os_password" ; public const string LoginInputCheckBoxRememberMe = "os_cookie" ; public const string LoginFormButton = "save" ; public const string DeployFormName = "executeManualDeployment" ; public const string DeployFormDeployButton = "save" ; public const string DeploymnetPageKeywordMatch = "Deployment:" ; public const string LoginPagekeywordMatch = "Build Dashboard" ; 1) Login to Bamboo (make sure to add error checking): WebClient = new WebClient(BrowserVersion.CHROME); // this is using NHtmlUnit 2.15, there is a Nuget package WebClient.Options.JavaScriptEnabled = false ; WebClient.Options.ActiveXNative = false ; WebClient.Options.CssEnabled = false ; .. HtmlPage page = WebClient.GetHtmlPage(Constants.BambooLoginPageUrl); HtmlForm form = page.GetFormByName(Constants.LoginFormName); var user = form.GetInputByName(Constants.LoginInputFieldUser) as HtmlTextInput; var pass = form.GetInputByName(Constants.LoginInputFieldPassword) as HtmlPasswordInput; var rememberLogin = form.GetInputByName(Constants.LoginInputCheckBoxRememberMe) as HtmlCheckBoxInput; user.SetValueAttribute(...); pass.SetValueAttribute(...); rememberLogin.SetChecked( true ); var submitButton = page.GetElementByName(Constants.LoginFormButton) as HtmlSubmitInput; var nextpage = submitButton.Click() as HtmlPage; 2) RunDeploymentUrl (again removed error checking): public static long RunDeploymentUrl(string url) { .. long deploymentResultId = Constants.DeploymentResultIdUnknown; var page = WebClient.GetHtmlPage(url); var form = page.GetFormByName(Constants.DeployFormName); .. HtmlSubmitInput submitButton = null ; //use try - catch , can get errors with this line form.GetByXPath( "//div[@class= 'aui-message error' ]/p/text()" ).FirstOrDefault().ToString(); submitButton = page.GetElementByName(Constants.DeployFormDeployButton) as HtmlSubmitInput; var nextpage = submitButton.Click() as HtmlPage; //add validation for nextpage.TitleText.Contains this can show issues with triggering the deployment, e.g. already in progress etc var query=HttpUtility.ParseQueryString(nextpage.Url.Query); var paramExtract=Int64.TryParse(query.Get( "deploymentResultId" ), out deploymentResultId); .. return deploymentResultId; } 3) You can get information about Bamboo deployment or its status using these SQL snippets (Atlassian, please expose it via WebAPI!) : -- get info about a deployment project given a versionId SELECT dv.[ NAME ] as ReleaseName, dp. NAME as ProjectName, DEPLOYMENT_VERSION_ID as DeploymentVersionId, dv.PROJECT_ID as PlanId, dp.PLAN_KEY as PlanKey FROM [dbo].[DEPLOYMENT_VERSION] dv inner join [dbo].[DEPLOYMENT_PROJECT] dp on dp.[DEPLOYMENT_PROJECT_ID]=dv.[PROJECT_ID] where DEPLOYMENT_VERSION_ID= @versionId --figure out what the prod environment is for a given Plan (we use Bamboo's Requirement task to mark environment as production) select dp.DEPLOYMENT_PROJECT_ID as PlanId, dp.PLAN_KEY as PlanKey, dp. NAME as PlanName, de. NAME as Name , de.ENVIRONMENT_ID as Id from dbo.DEPLOYMENT_ENVIRONMENT de join dbo.DEPLOYMENT_PROJECT dp on dp.DEPLOYMENT_PROJECT_ID = de.[PACKAGE_DEFINITION_ID] where de.XML_DEFINITION_DATA like '%Permission.Deploy.Prod%' and DEPLOYMENT_PROJECT_ID= @PlanI -- get deployment status , -- Life Cycle is Unknown , NotBuilt, InProgress, Queued, Finished -- If LifeCycle is Finished, then can check State to see the status (either Unknown , Failed, Successful ) select DEPLOYMENT_RESULT_ID as DeploymentResultId, DEPLOYMENT_STATE as StateString, LIFE_CYCLE_STATE as LifeCycleString, STARTED_DATE as StartedOn, EXECUTED_DATE as ExecutedOn, FINISHED_DATE as FinishedOn, VERSION_ID as DeploymentVersionId, ENVIRONMENT_ID as EnvironmentId from dbo.DEPLOYMENT_RESULT where DEPLOYMENT_RESULT_ID=@deploymentResultId

            DaveT added a comment -

            We're looking at IBM UrbanCode Deploy (formerly AntHill Pro), OpenMake Release Manager, and Nolio. The idea of having an inventory of environments made up of servers that contain a specific arrangement of deployed applications is something that's just not there with Bamboo. All of these products allow you to define role-based permissions within the environments, apply configuration control to the installation process, and establish sane artifact promotion through a series of environments leading to production.

            Bamboo's deployment capabilities are probably okay for small teams with a limited number of environments, but the products mentioned here are more comprehensive for the enterprise, particularly ones that aren't entirely relying on fully automated environment provisioning and testing.

            DaveT added a comment - We're looking at IBM UrbanCode Deploy (formerly AntHill Pro), OpenMake Release Manager, and Nolio. The idea of having an inventory of environments made up of servers that contain a specific arrangement of deployed applications is something that's just not there with Bamboo. All of these products allow you to define role-based permissions within the environments, apply configuration control to the installation process, and establish sane artifact promotion through a series of environments leading to production. Bamboo's deployment capabilities are probably okay for small teams with a limited number of environments, but the products mentioned here are more comprehensive for the enterprise, particularly ones that aren't entirely relying on fully automated environment provisioning and testing.

            Johannes A added a comment -

            @Dave, I'm also interested to learn what other products you are considering for deployment handling.

            Johannes A added a comment - @Dave, I'm also interested to learn what other products you are considering for deployment handling.

            @Dave Thomas , what are you using? We too are at tipping point on this and are reviewing better fits.

            Jacob Briggs added a comment - @Dave Thomas , what are you using? We too are at tipping point on this and are reviewing better fits.

            DaveT added a comment -

            After waiting for several years, we've basically given up on using Bamboo to handle deployments. We're currently evaluating a couple of other projects in the DevOPS space that handle deployments and artifact promotion much more effectively. We'll continue to use Bamboo for building things, but Atlassian is really way too far behind the other vendors in this space to be useful for deployements in our enterprise setting.

            DaveT added a comment - After waiting for several years, we've basically given up on using Bamboo to handle deployments. We're currently evaluating a couple of other projects in the DevOPS space that handle deployments and artifact promotion much more effectively. We'll continue to use Bamboo for building things, but Atlassian is really way too far behind the other vendors in this space to be useful for deployements in our enterprise setting.

            We want to extract information of all Deployments happened under a project (we have 60 environments under one project) for past 1 month, but there is no such REST API is available, the farthest we can get is all latest deployment happen and run a scripts which trigger this query for every 5-7 mins, gather a one month deployment data and store somewhere in our database.
            Is there anyone who have some better suggestion to gather this data using REST API or any other means?

            Saifuddin Tariwala added a comment - We want to extract information of all Deployments happened under a project (we have 60 environments under one project) for past 1 month, but there is no such REST API is available, the farthest we can get is all latest deployment happen and run a scripts which trigger this query for every 5-7 mins, gather a one month deployment data and store somewhere in our database. Is there anyone who have some better suggestion to gather this data using REST API or any other means?

            fadiabdeen added a comment -

            This is a blocker for us when we started implementing continuous deployment , we want to trigger deploy from outside bamboo and we are stuck at this point. really prefer not using build plans for deployment as we will lose all the deployment features.

            fadiabdeen added a comment - This is a blocker for us when we started implementing continuous deployment , we want to trigger deploy from outside bamboo and we are stuck at this point. really prefer not using build plans for deployment as we will lose all the deployment features.

            agree this is huge. surprised its not been added already.

            Shaunt Kojabashian added a comment - agree this is huge. surprised its not been added already.

            jeff mease added a comment -

            I could really use this feature. It would allow me to be able to tie together a post function action in a jira workflow to kick off a deployment to an environment. I could even expand that to a separate Issue type for each environment and have the whole approval and action done with one click .

            jeff mease added a comment - I could really use this feature. It would allow me to be able to tie together a post function action in a jira workflow to kick off a deployment to an environment. I could even expand that to a separate Issue type for each environment and have the whole approval and action done with one click .

            An option (one that I use for our build plan atm) is to trigger a 'dummy' build plan via API call from a script task. Your main build plan (I use one for all our repositories and environments) can execute this call and pass variables useful for deployment, the dummy plan then completes successfully and triggers the associated deploy plan. I have one for dev envs and one for prod envs, the main build plan triggers one of these two depending upon the source and destination of the original build.

            Jay Carroll added a comment - An option (one that I use for our build plan atm) is to trigger a 'dummy' build plan via API call from a script task. Your main build plan (I use one for all our repositories and environments) can execute this call and pass variables useful for deployment, the dummy plan then completes successfully and triggers the associated deploy plan. I have one for dev envs and one for prod envs, the main build plan triggers one of these two depending upon the source and destination of the original build.

            This option is something that's been hitting us here at the Disney studio also; we want to string together a pipeline of various different types of plans but it's a pretty serious impediment.

            gustavo-cordovaavila added a comment - This option is something that's been hitting us here at the Disney studio also; we want to string together a pipeline of various different types of plans but it's a pretty serious impediment.

            update????

            Deleted Account (Inactive) added a comment - update????

            Hi,

            I just wanted to provide an update on this request. At this stage it's unlikely that we'll address it before the end of the year. We've been working on some improvements for creating/updating plans but we are still pending some more development and testing before we can release it.

            Thanks everyone for your feedback, please know that we read it and take it into account when prioritising our roadmap but due to other factors we are unable to put this development on top of the backlog.

            Thanks,

            Sten Pittet
            Bamboo Product Manager

            Sten Pittet (Inactive) added a comment - Hi, I just wanted to provide an update on this request. At this stage it's unlikely that we'll address it before the end of the year. We've been working on some improvements for creating/updating plans but we are still pending some more development and testing before we can release it. Thanks everyone for your feedback, please know that we read it and take it into account when prioritising our roadmap but due to other factors we are unable to put this development on top of the backlog. Thanks, Sten Pittet Bamboo Product Manager

            I am also waiting with bated breath for this ticket!

            Alex Ferguson added a comment - I am also waiting with bated breath for this ticket!

            I've been waiting expectantly for this feature, coming back to check every few months and every time there's a new release of Bamboo. Would anyone care to comment on whether any kind of solution is coming. I'm sorry but It seems to be a big gaping hole in the API rather than just a niche nice-to-have! Thanks.

            Alex Williams added a comment - I've been waiting expectantly for this feature, coming back to check every few months and every time there's a new release of Bamboo. Would anyone care to comment on whether any kind of solution is coming. I'm sorry but It seems to be a big gaping hole in the API rather than just a niche nice-to-have! Thanks.

            Why atlassian has this issue tracking if nobody from the Atlassian team actually help to solve them?

            Cesar Campana added a comment - Why atlassian has this issue tracking if nobody from the Atlassian team actually help to solve them?

            Michael T added a comment -

            2+ years later... sigh

            Michael T added a comment - 2+ years later... sigh

            Alex Dess added a comment -

            I too want to see this feature.

            Alex Dess added a comment - I too want to see this feature.

            I wash happy to see this ticket. Sad to see its not going anywhere.

            george.whitaker added a comment - I wash happy to see this ticket. Sad to see its not going anywhere.

            Johannes A added a comment -

            In an enterprise context where approval processes are often centralized and handled in dedicated tools, being able to trigger (production) deployments from outside via a clean API is of strategic importance. We would love to see REST API support for this in Bamboo soon. The current workaround documented here is indeed only a workaround due to its shoot-and-forget nature. Many thanks for putting effort into this.

            Johannes A added a comment - In an enterprise context where approval processes are often centralized and handled in dedicated tools, being able to trigger (production) deployments from outside via a clean API is of strategic importance. We would love to see REST API support for this in Bamboo soon. The current workaround documented here is indeed only a workaround due to its shoot-and-forget nature. Many thanks for putting effort into this.

            We are looking to automate the provisioning process of our build/deployment plans to better empower our customers. Below I have identified as gaps with the current API which would help us to accomplish this. Obviously since this ticket hasn't been updated in nearly two years I'm not overly hopeful.

            1. Create deployment environments
            2. Copy deployment environments
            3. Change build plan repo
            4. Change build plan variables
            5. Add build plan task
            6. Modify build plan task

            Tyler_Carrington added a comment - We are looking to automate the provisioning process of our build/deployment plans to better empower our customers. Below I have identified as gaps with the current API which would help us to accomplish this. Obviously since this ticket hasn't been updated in nearly two years I'm not overly hopeful. Create deployment environments Copy deployment environments Change build plan repo Change build plan variables Add build plan task Modify build plan task

            Ben Lucato added a comment -

            The documentation on this API is just so poor... what is the use of all these endpoints https://docs.atlassian.com/bamboo/REST/5.7.0/ if most are not documented?

            Ben Lucato added a comment - The documentation on this API is just so poor... what is the use of all these endpoints https://docs.atlassian.com/bamboo/REST/5.7.0/ if most are not documented?

            Ben Lucato added a comment -

            There is no timeline for this??? This is such a wanted feature at my workplace. Jira's REST API is amazing and you can do heaps with it, but Bamboo's is lackluster in comparison.

            Ben Lucato added a comment - There is no timeline for this??? This is such a wanted feature at my workplace. Jira's REST API is amazing and you can do heaps with it, but Bamboo's is lackluster in comparison.

            a few more suspicious ones

            /deploy/project
            /deploy/project/forPlan?planKey

            Christopher Fitzner added a comment - a few more suspicious ones /deploy/project /deploy/project/forPlan?planKey

            There are some interesting looking methods related to deployments in the latest rest api version:

            https://docs.atlassian.com/bamboo/REST/5.7-SNAPSHOT/

            /deploy/version maybe?

            Christopher Fitzner added a comment - There are some interesting looking methods related to deployments in the latest rest api version: https://docs.atlassian.com/bamboo/REST/5.7-SNAPSHOT/ /deploy/version maybe?

            Aaron Boushley added a comment - https://confluence.atlassian.com/display/DEV/Implementation+of+New+Features+Policy?continue=https%3A%2F%2Fconfluence.atlassian.com%2Fdisplay%2FDEV%2FImplementation%2Bof%2BNew%2BFeatures%2BPolicy&application=cac

            I wonder how Atlassian determines top 20 issues. Their policy is that they consistently update the top 20 issues, however this is issue #15 by votes and there's no commentary from Atlassian. So either they mean top 20 across all of their projects (which would be ridiculous) or they have some other way of ordering which doesn't involve customer input.

            Aaron Boushley added a comment - I wonder how Atlassian determines top 20 issues. Their policy is that they consistently update the top 20 issues, however this is issue #15 by votes and there's no commentary from Atlassian. So either they mean top 20 across all of their projects (which would be ridiculous) or they have some other way of ordering which doesn't involve customer input.

            Chris Riley, where do you see the API for this? What endpoints are you seeing that make you think it exists?

            Aaron Boushley added a comment - Chris Riley, where do you see the API for this? What endpoints are you seeing that make you think it exists?

            It appears the API exists but documentation does not share the JSON payload necessary to perform the activity. Can someone comment from Atlassian on whether this feature will be documented and when?

            Chris Riley added a comment - It appears the API exists but documentation does not share the JSON payload necessary to perform the activity. Can someone comment from Atlassian on whether this feature will be documented and when?

            And just to follow up, as of version 5.4.2 build 4208 - 03 Mar 14, the workaround no longer works. The form is secured now with the atl_token and xsrf cookies being posted as formdata from the page which is injected via some sort of secure javascript mechanism.

            So now there is no REST API, and apparently no workaround. This must be fixed or addressed soon, this wing of the application is now completely inaccessible from API.

            Eric Fusciardi added a comment - And just to follow up, as of version 5.4.2 build 4208 - 03 Mar 14, the workaround no longer works. The form is secured now with the atl_token and xsrf cookies being posted as formdata from the page which is injected via some sort of secure javascript mechanism. So now there is no REST API, and apparently no workaround. This must be fixed or addressed soon, this wing of the application is now completely inaccessible from API.

            @Jason Monsorno's hack needs some changes [at least as of version 5.3 build 4101 - 09 Dec 13]. You must also not have XSRF enabled [for obvious reasons]

            Form params have changed, an example post looks like this now:

            http://bamboo/deploy/executeManualDeployment.action?environmentId=123456789&newReleaseBuildResult=PROJ-PLAN-1&releaseTypeOption=PROMOTE&promoteVersion=releaseNameHere&save=Start deployment

            Eric Fusciardi added a comment - @Jason Monsorno's hack needs some changes [at least as of version 5.3 build 4101 - 09 Dec 13] . You must also not have XSRF enabled [for obvious reasons] Form params have changed, an example post looks like this now: http://bamboo/deploy/executeManualDeployment.action?environmentId=123456789&newReleaseBuildResult=PROJ-PLAN-1&releaseTypeOption=PROMOTE&promoteVersion=releaseNameHere&save=Start deployment

            I hate putting code snippets on here because everything is a workaround so it's just thrown together but whatever, fairly warned.
            First we use /rest/api/latest/deploy/dashboard to get all the deployment projects and display them on single page, we have almost 100 projects each with 2 deployment. The first deployment is triggered on build and the second we only want to allowed the latest successful build so we allow people to "Promote" anything where first deployment releaseName != second deployment releaseName. I was already using RestSharp so I decided to just stick with it, it's all C# so Java lovers just think of it as Pseudo code.

            PromotionReleaseId is coming from the API listed above and filtered to our second deployment environment (by name) on whatever project was selected.

                        RestClient client = new RestClient("http://bamboo1");
                        RestRequest login = new RestRequest("/userlogin.action", Method.POST);
                        login.AddParameter("os_username", "api");
                        login.AddParameter("os_password", "********");
                        login.AddParameter("save", "Log in");
                        var loginResponse = client.Execute(login);
                        RestRequest getHiddenValues = new RestRequest("deploy/selectVersionForExecute.action", Method.GET);
                        foreach (var cookie in loginResponse.Cookies)
                            getHiddenValues.AddCookie(cookie.Name, cookie.Value);
                        getHiddenValues.AddParameter("environmentId", PromotionReleaseId);
                        var response = client.Execute(getHiddenValues);
                        string startString = "<input type=\"hidden\" name=\"latestVersionId\" value=\"";
                        var indexOfStart = response.Content.IndexOf(startString) + startString.Length;
                        var indexOfEnd = response.Content.IndexOf("id=", indexOfStart);
                        var latestVersionId = response.Content.Substring(indexOfStart, indexOfEnd - indexOfStart - 2);
                        //<input type="hidden" name="latestVersionId" value="65700009" id="latestVersionId">
                        RestRequest request = new RestRequest("/deploy/executeManualDeployment.action", Method.POST);
                        request.AddParameter("environmentId", PromotionReleaseId);
                        request.AddParameter("existingVersionOption", "LATEST");
                        request.AddParameter("latestVersionId", latestVersionId);
                        request.AddParameter("existingVersion", "");
                        request.AddParameter("save", "Start deployment");
                        foreach (var cookie in loginResponse.Cookies)
                            request.AddCookie(cookie.Name, cookie.Value);
                        var restResponse = client.Execute(request);
            

            Warning, this code is designed to release the latest available, even if my users click on "previous" release if one was occurring and had finished between them clicking and the code executed. Since we want a YES/NO per project, this works fine for us.

            Jason Monsorno added a comment - I hate putting code snippets on here because everything is a workaround so it's just thrown together but whatever, fairly warned. First we use /rest/api/latest/deploy/dashboard to get all the deployment projects and display them on single page, we have almost 100 projects each with 2 deployment. The first deployment is triggered on build and the second we only want to allowed the latest successful build so we allow people to "Promote" anything where first deployment releaseName != second deployment releaseName. I was already using RestSharp so I decided to just stick with it, it's all C# so Java lovers just think of it as Pseudo code. PromotionReleaseId is coming from the API listed above and filtered to our second deployment environment (by name) on whatever project was selected. RestClient client = new RestClient( "http: //bamboo1" ); RestRequest login = new RestRequest( "/userlogin.action" , Method.POST); login.AddParameter( "os_username" , "api" ); login.AddParameter( "os_password" , "********" ); login.AddParameter( "save" , "Log in" ); var loginResponse = client.Execute(login); RestRequest getHiddenValues = new RestRequest( "deploy/selectVersionForExecute.action" , Method.GET); foreach ( var cookie in loginResponse.Cookies) getHiddenValues.AddCookie(cookie.Name, cookie.Value); getHiddenValues.AddParameter( "environmentId" , PromotionReleaseId); var response = client.Execute(getHiddenValues); string startString = "<input type=\" hidden\ " name=\" latestVersionId\ " value=\" "; var indexOfStart = response.Content.IndexOf(startString) + startString.Length; var indexOfEnd = response.Content.IndexOf( "id=" , indexOfStart); var latestVersionId = response.Content.Substring(indexOfStart, indexOfEnd - indexOfStart - 2); //<input type= "hidden" name= "latestVersionId" value= "65700009" id= "latestVersionId" > RestRequest request = new RestRequest( "/deploy/executeManualDeployment.action" , Method.POST); request.AddParameter( "environmentId" , PromotionReleaseId); request.AddParameter( "existingVersionOption" , "LATEST" ); request.AddParameter( "latestVersionId" , latestVersionId); request.AddParameter( "existingVersion" , ""); request.AddParameter( "save" , "Start deployment" ); foreach ( var cookie in loginResponse.Cookies) request.AddCookie(cookie.Name, cookie.Value); var restResponse = client.Execute(request); Warning, this code is designed to release the latest available, even if my users click on "previous" release if one was occurring and had finished between them clicking and the code executed. Since we want a YES/NO per project, this works fine for us.

            Would love to see a code snippet of that if you have one.

            Glenn Brown added a comment - Would love to see a code snippet of that if you have one.

            We've been doing this for months without an API. All you need to do is authenticate and POST /deploy/executeManualDeployment.action with environmentId, existingVersionOption = "LATEST", latestVersionId, existingVersion, & save = "Start deployment". Would like an API to make it cleaner but no API isn't going to stop me.

            Jason Monsorno added a comment - We've been doing this for months without an API. All you need to do is authenticate and POST /deploy/executeManualDeployment.action with environmentId, existingVersionOption = "LATEST", latestVersionId, existingVersion, & save = "Start deployment". Would like an API to make it cleaner but no API isn't going to stop me.

            Any update about ETA, please?

            Sergey Erlikh added a comment - Any update about ETA, please?

            Any news here ? Atlassian are great at producing services with a rest api included, would be nice not to loose focus on the deployment part of bamboo.

            Paul Gilligan added a comment - Any news here ? Atlassian are great at producing services with a rest api included, would be nice not to loose focus on the deployment part of bamboo.

            Any ETA on that? this would really really improve my Deployment Plans. I made a fully bamboo configurable App which allows us to deploy several projects on several environments... just need the api to finish it.

            David Zahorsky added a comment - Any ETA on that? this would really really improve my Deployment Plans. I made a fully bamboo configurable App which allows us to deploy several projects on several environments... just need the api to finish it.

            Agreed. If Atlassian would add a way to trigger deployments from the build plan they would have something pretty cool. I am still anxiously waiting for this.

            Jason Kirton (Inactive) added a comment - Agreed. If Atlassian would add a way to trigger deployments from the build plan they would have something pretty cool. I am still anxiously waiting for this.

            The workaround for now is to separate your deployment into a build stage within a plan, but configure the stage to be Manual.

            Then, a Bamboo API call can trigger the Deployment stage, as such:

            curl -s -u user:passwd -X PUT -H "Content-type: application/json" "http://bamboo.myinstance.com/rest/api/latest/queue/PLAN-BRANCH-65.json?DEP"

            ...where "DEP" is the short job key.

            *NOTE:* This will only work if the stage is in a state allowing "resume execution." In other words, you can't use this to re-run the stage programmatically.

            IMHO, having separate deployment plans is near-useless until they can be controlled programmatically.

            Ted Sheibar added a comment - The workaround for now is to separate your deployment into a build stage within a plan, but configure the stage to be Manual. Then, a Bamboo API call can trigger the Deployment stage, as such: curl -s -u user:passwd -X PUT -H "Content-type: application/json" "http://bamboo.myinstance.com/rest/api/latest/queue/PLAN-BRANCH-65.json?DEP" ...where "DEP" is the short job key. * NOTE: * This will only work if the stage is in a state allowing "resume execution." In other words, you can't use this to re-run the stage programmatically. IMHO, having separate deployment plans is near-useless until they can be controlled programmatically.

              Unassigned Unassigned
              ssetayeshfar Sepideh Setayeshfar (Inactive)
              Votes:
              193 Vote for this issue
              Watchers:
              152 Start watching this issue

                Created:
                Updated:
                Resolved: