Plugin installation on TeamCity - c#

according to the documentation, installation for tcWebhooks is as follows
Download the jar file. Locate the plugins directory for your TeamCity
install. This is normally $HOME/.BuildServer/plugins/. Create a new
directory (folder) inside the plugins directory called "tcWebHooks"
(it can be named whatever you want). Copy the jar you downloaded into
the tcWebHooks directory. Restart TeamCity.
TeamCity Professional 7.1.4 (build 24331) didn't create a .BuildServer folder and I cannot find that anywhere on my machine. Does anyone know the default path for the installation of plugins? I see there is a plugins folder at "C:\TeamCity\buildAgent\plugins" which contains a lot of plugins but following the above instructions still doesn't seem to pick up the plugin.

You should put your plug-ins into server. They will be deployed to agents automatically.
Just copy the zip file of the plugin into the plugins folder in the teamcity data folder, which by default is C:\ProgramData\JetBrains\Teamcity\plugins.
If you are not sure you can find it under administration > global settings

Related

Windows installer (MSI) does not copy a config file

I installed an MSI buillder tool on my visual studio 2017 and started deploying my desktop application with generated MSIs. The istaller is able to copy vital files and adds registery keys but it does not copy some additional config files which are required for logger. According to this page, switching "Copy to Output Directory Property" to "Copy always" supposed to take care the issue however, it still does not copy the config file into output directory on client's computer.
Can somebody give an advice about how I can diagnose this problem ?
Edit:
I think I can explicitly add logs files into MSI with following method but I have two concerns on this. Would I add the file into MSI with its global or relative path ? Secondly will it be a good practice ?
Edit 2:
For the reference for developers who has the same issue, looks like the method stated above adds files with its relative path. I added screenshot of difference page at source control.
It is completely normal to add individual files to a VS setup project. Every tool that generates an MSI works this way. VS setups are probably the exception with their "project output" type of input choice, where you get little idea of the actual files that will be installed. So you get the best control of the MSI content by adding each file individually, including that config file. Also, some files really don't belong in the Application Folder (that defaults to Program Files) because they are data files that belong somewhere like the User's Application Data.
The path where the MSI build gets its files from is nothing to do with where that file is deployed on the target system. You tell the MSI build where files will be deployed on the target system by using the File System view on target machine, where you get a list of destination folders to add files to.
Also, the copy to output directory stuff is nothing to do with the build of the MSI file. As far as I know, its main reason is to allow you to have all dependencies at the output build location of the code so that the program will work correctly from that location, and it happens to give you the opportunity to get all the files going into a setup from the same place. It does not mean "copy this file somewhere in such a way that it is automatically included in the MSI build and the deployed on the target system".
Once you get the MSI working and installing the config file, you may run into Windows Installer file overwrite rules that prevent you from overwriting files that have been updated after they were installed.

Change the WixBundleExecutePackageCacheFolder for Custom Wix Bundle installer

I have a custom wixtoolset 3.10.2 bundle that installs 8 different .msi packages. I need to have the extraction/cache folder for the bundle be a folder different than the the standard "C:\Users\myuser\AppData\Local\Temp". Is this possible? I need to do this because we are not allowing any executable to run from this standard temp folder for security reasons. I would like the cache folder to be something like "C:\MyCompany\Install\Temp" That way I can 'whitelist' that folder.
You can redirect the package cache but you cannot change where Burn extracts the BA from the bundle for use during initialization.
As part of the work done for #5830 and #5856 in v4, Burn can have separate locations for the extraction folder (where the clean room process and the elevated process will start from) and the acquisition folder (where payloads are copied/downloaded to before moving to the Package Cache folder). Note that none of these are WixBundleExecutePackageCacheFolder, which is a dynamic value that indicates where a specific package is currently executing from.
The acquisition folder is still not configurable and uses %TEMP%. Burn should not execute files from here so that should be sufficient.
The extraction folder still defaults to %TEMP% but can be overridden on the command line (-burn.working.directory=<path>) or in the registry (EngineWorkingDirectory in HKLM\Software\Policies\WiX\Burn).

A C# Setup Project that will copy an additional file if it exists in the SOURCE folder

I've created a setup project which works just fine. However, I'd like to have the ability where if I were to place a config.ini file inside the SOURCE directory of the setup.exe file, this will be copied to the installation directory during installation.
So if there is no config.ini file in the setup folder, the installer would run as normal. But if there is one, this would be copied over to the installation directory on the client machine.
Does anyone know if this is possible, and if so... how?
Many thanks in advance.

VS2013: never put bin directory in source control, but it caused build fail

I'm new in Visual Studio 2013 (C#). I know in general it should be avoid putting bin directory in source control. However, in my bin directory, there are lots of dll files. Without this dlls, I can't build my project.
I thought maybe I should create a directory, such as 'lib' to store the dlls. But the fact is NuGet always put dll into the bin directory. Should I manually move the dll from bin to lib?
All I want is to simply put all source codes, resource files and dll files to source control (git). Then my team-mates can pull the project then build it in their machine.
edit on 1/4/2015: provide further details
For example, I installed log4net thru NuGet. After finished, I found 3 new files existed in bin directory:
log4net.dll
log4net.xml
log4net.dll.refresh
I tried to remove bin directory from my project, then rebuild my project, and hope to see that a new bin directory would be built and all dll/pdb/etc files would come back. But unfortunately it didn't happen.
In my understanding, the ideal process would be:
add reference/install package, then certain config info would be recorded and according files would be installed to bin directory;
when build, according lib files would be referenced from bin, if such files not found, VS would get the reference info from some place other than bin and download them again. So that's one of the reasons why we don't need to put bin into source control.
However, I found that's not true in my project.
Actually according to the official .gitignore, I found bin directory as build results is filtered ([Bb]in/). That is to say, even VS knows such directory should be ignored.
Maybe some wrong setting within my project?

Clickonce missed out folder in bin

Hi how do i publish the files from my bin folder using clickonce?
i successfully copied a folder of .sql script to the bin folder using the Build Events xcopy "$(ProjectDir)\..\project.Sql\AlterProductionServer" "$(TargetDir)\AlterProductionServer" /i /y
My purpose for doing that is to ask the system to check for any database script changes on startup. The system will check the scripts from the bin folder. The reason i xcopy to the bin so that when deploy, my client pc will read it from the same location too. If found, then it will run the .sql scripts to update the database first before running the system.
However, when i clicked on Publish - > Application Files, i do not see the AlterProductionServer folder which contain .sql files that i have already copied to the bin appear for me to choose to Include.
please advice.
When publishing via ClickOnce from within the Visual Studio IDE, it will only offer files from the project/solution, not from the file system. You could add your .sql file to the project, set the build action to Content and specify that it be copied to the output directory. This removes the need for your xcopy build action and makes VS aware of the importance of the file.
If it will still not show in the Application Files section after a rebuild, you may have to look at the prospect of writing your own application/deployment manifest files (XML) and using the command-line ClickOnce utilities to publish your solution. I found this was necessary when including items in my ClickOnce distribution which were not dependencies of the main project.

Categories

Resources