Checkout previous success version (revision) in teamcity - integration

Oure teamcity server (6.5) configured to checkout sources from SVN. For some build proceess cases I need checkout previous successfully builded version(revision). Can teamcity do this? And if can, how to configure checkout?

It sounds like you're looking for TeamCity Snapshot Dependencies, with the "Only use successful builds from suitable ones" option.
You'd end up with two build configurations:
Performs initial builds on commit to SVN
Has a snapshot dependency on #1, so when this build runs (either automatically - via a trigger - or manually), it grabs the same sources as the last successful build of #1.
Both of the build configurations would use the same VCS root.

Related

How must Teamcity be configured to work withtout SVC?

I am new in Teamcity and I created a Build, with a RunScript step.
I changed nothing in the source control configuration of this step.
The goal of the Build step is to run a script nothing else.
When running the build, Teamcity tries to do a source checkout (not configured) and stays blocked there.
What is the correct Teamcity SVC configuration in order that the build works even when SVC is not configured? Is it even possible or I should configure a fake SVC system like GIT to get it running?
With Teamcity, as with TFS, when you want to handle UI Tests, you should install the Test Agents as Interactive and not as Service.
If you Install them as Services, you will not have access to all the functionalities you need for UI testing.

Can I modify my openshift git repo using ssh shell?

I have working app on OpenShift server. My question is - how to update openshift's git repo of my application, if I make some changes using ssh acsess to openshift? I mean not using all this stuff with pull/push to my local mashine.
If I understand you correctly, you would like to modify source code without using git. I am not sure why you would want that. All that stuff with pull/push gives you a version control flexibility which can save you a lot of time when you screw up one thing. For example, you push brand new UI to production, which turns out to be buggy. With git, you have flexibility to revert back to previous version, and work on different branch to fix the bug on UI.
OpenShift follows conventional app structure. Git for source control, maven for build, jbosseap(for example) for app server, jenkins for continuous integration, etc. So, when you push using git, OpenShift will automatically build using maven, then deploy to the server.
If you would like to disregard all that advantages that OpenShift has to offer, use rhc ssh appname to directly work on the server.

On TeamCity, Mercurial repo is checked out without execute bit set

In my Mercurial repository, I have some build scripts. However, when TeamCity checks out the repo, it doesn't set the execute bit on them, even though it's set in the repository. The build then fails, as it can't run the scripts, as you would expect. How do I make TeamCity respect the execute bit?
I am running TeamCity 9.0 on Ubuntu Server 14.04.
Changing the VCS checkout mode to Agent rather than Server fixed this problem for me.
To change the VCS checkout mode:
On the project configuration settings, go to Version Control Settings
Click on Show advanced options
Change VCS checkout mode from Automatically on server to Automatically on agent

How do I choose an artifact from Nexus in a Hudson / Jenkins job?

I have a job in Hudson server A which builds an artifact and deploys it to Nexus. I have another job in a completely separate Hudson server B which needs to download the artifact and deploy it. This job is normally run manually, and the person running it needs to indicate which version of the artifact to deploy - they may not always want to deploy the latest version (e.g. to roll back to a previous known good version).
Currently, I achieve this by using a parameterized build, and require the user to pass in the artifact version number; the job then uses the Execute shell build step to run wget on a URL constructed using the parameter. This is error prone.
Ideally I'd like a plugin that lets the user browse the artifact versions in the Nexus repository and pick and choose the one to deploy, but I'm open to other suggestions. A plugin that also handles the download would be nice, but I can live without it as long as I can still get a string that I can use in shell commands.
I've looked through the available Hudson & Jenkins plugins around Maven style artifact repositories, but they all seem more concerned with pushing artifacts into repos rather than getting them back down.
I'm using Hudson's "Copy Artifact" in other jobs, to get artifacts from other Hudson jobs on the same server, but this doesn't work across different Hudson servers, which is why I've turned to Nexus (which we're already using anyway).
Does anyone have any suggestions?
I recommend using rundeck to execute your deployments.
There is a rundeck plugin for Nexus that enables rundeck to display a pull down menu of available versions in Nexus.
There is a rundeck plugin for Jenkins that can be used to invoke deployments using rundeck and kick-off post deployment jobs (like integration testing) inn Jenkins.

How do I remove the -C parameter from cvs update in a Hudson build

I can't find where I can configure the parameters that hudson uses in CVS checkout and update.
I have a situation where I modify build properties file locally before I kick off a hudson build. However because the cvs update contains a '-C' it overwrites my local changes. Do you know of a way where I can remove this?
Any help much appreciated,
Paul
You are confusing me. How do you change the build properties locally before kicking off the build? If I need to do something like that, I first get the code from my SCM and then run a script to make changes (like changing the build properties) and than start the actual build process (usually by kicking off maven or ant). The whole purpose of a CI (what Hudson is supposed to be used for) is to have a reproducible build. Manual steps during a build usually do not count as reproducible.