MSBuild and Octopack | Not creating package

Hi,

I am new to Octopack, am trying to use Octopack to build a sitecore solution. It is creating package when I build from visual studio but it does not create anything when using MSBuild.

Following is the command that I use.
msbuild “C:\Users\XX\Source\Repos\Niddk\Niddk\Niddk.sln” /t:Clean /p:RunOctoPack=true /p:VisualStudioVersion=14.0 /p:Configuration=Release

Do I need to make any changes to target to make this work?

Thanks,
~ Antony

Hi Antony,

Thanks for reaching out. The only changes to targets that need to be done in your csproj file are done automatically when you add Octopack to your project. If you check the changes to the csproj file in this commit, you’ll see what gets added by Octopack when you add it to your project: https://github.com/Dalmirog/TaskTracker/commit/eee346aa1d6c426fb60ef48c41308a2636861003

Couple of questions and requests:

  1. How are you building your project from Visual Studio (where you say the package is being created)? Screenshots here would be the best.

  2. When you are running that MSBuild command, are you doing it on your workstation or is it being executed by a build server?

  3. Could you send us the content of your csproj file?

Best regards,
Dalmiro

Hi,

Thanks for your response.

I am using Team city to build our sitecore solution and was getting error on build. I have fixed the build issue, it was because I was not including nuget installer before the build and thus was not able to include Octopack.

I have a few related questions

· Once build is complete, where does the package gets created? I see bin and obj folders empty once build is complete and successful. I have “Run Octopack” selected in team city.

· We are building a package for Sitecore solution and uses TDS (https://www.teamdevelopmentforsitecore.com/). Do you have any insight on how to deploy TDS project content into Sitecore? I am following the steps mentioned in this blog: http://goblinrockets.com/2013/11/03/continuous-integration-deployment-with-sitecore/ , but I am not able to include specific files from TDS project.

I am attaching csproj file for one of the project, appreciate your help.

Thanks,
~ Antony

Sitecore-CSProj.zip (1 KB)

Hi Antony,

Once build is complete, where does the package gets created? I see bin and obj folders empty once build is complete and successful. I have “Run Octopack” selected in team city.

On your build output you should see Octopack getting executed (see green arrow in attached screenshot). The log should also show where the package has been created (red arrow). Do you see these entries in your build log? If not, you might wanna uninstall Octopack from your project, re-install it and try again. Once you do that, please send us your build log.

We are building a package for Sitecore solution and uses TDS (https://www.teamdevelopmentforsitecore.com/). Do you have any insight on how to deploy TDS project content into Sitecore? I am following the steps mentioned in this blog: http://goblinrockets.com/2013/11/03/continuous-integration-deployment-with-sitecore/ , but I am not able to include specific files from TDS project.

The doc below shows how to tell Octopack to include files from outside of the build. Unfortunately we don’t have experience with Sitecore projects. But I’m sure that once you solve the Octopack issue, you’ll be able to make use of the link below to add the extra files you need.

Best regards,
Dalmiro.

Hi,

Thanks for your response. I was able to get it to work after uninstall and installing it back again.

I am now using Octopus to deploy the package to a server and am not able to use it correctly. I am running into couple of issues

  1.   When I create a target environment, the tentacle url is asking for https and not allowing me for a http site. Our test environments are not secured.
    
  2.   While trying to deploy a nuget package, it cannot identify nuget package id. The package is created by team city using octopack and I am using “Octopus deploy” in Team city. I have couple of packages created in MSBuild in team city, is this creating an issue.
    

Looking forward to hear from you.

Thanks,
Antony John Zacharias
Manager, Technology | Sapient Government Services

1515 N Courthouse Rd
Arlington, VA 22201
United States

Desk: +1 703 908 2586
Mobile: +1 703 473 3576
Fax: +1 703 908 2401
Email: azacharias@sapient.commailto:azacharias@sapient.com

sapient.com/government

The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer.

Please consider the environment before printing this email.

Hi,

I understand a little more now and am able to deploy the package to my server. My issue now is on how to deploy my dll’s and other items within the .nupkg file. Should I use powershell or something else to extract the files and then copy the files to the appropriate locations?

Thanks,
Antony John Zacharias
Manager, Technology | Sapient Government Services

1515 N Courthouse Rd
Arlington, VA 22201
United States

Desk: +1 703 908 2586
Mobile: +1 703 473 3576
Fax: +1 703 908 2401
Email: azacharias@sapient.commailto:azacharias@sapient.com

sapient.com/government

The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer.

Please consider the environment before printing this email.

From: Antony John Zacharias
Sent: Thursday, February 18, 2016 2:27 PM
To: 'Dalmiro Grañas’
Subject: RE: MSBuild and Octopack | Not creating package [Problems #44507]

Hi,

Thanks for your response. I was able to get it to work after uninstall and installing it back again.

I am now using Octopus to deploy the package to a server and am not able to use it correctly. I am running into couple of issues

  1.   When I create a target environment, the tentacle url is asking for https and not allowing me for a http site. Our test environments are not secured.
    
  2.   While trying to deploy a nuget package, it cannot identify nuget package id. The package is created by team city using octopack and I am using “Octopus deploy” in Team city. I have couple of packages created in MSBuild in team city, is this creating an issue.
    

Looking forward to hear from you.

Thanks,
Antony John Zacharias
Manager, Technology | Sapient Government Services

1515 N Courthouse Rd
Arlington, VA 22201
United States

Desk: +1 703 908 2586
Mobile: +1 703 473 3576
Fax: +1 703 908 2401
Email: azacharias@sapient.commailto:azacharias@sapient.com

sapient.com/government

The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer.

Please consider the environment before printing this email.

Hi Anthony,

Octopus takes care of extracting the package’s contents by default. After extracting everything in a working/temp dir, it can copy them to the directory of your choice by using the Custom Installation Directory feature

Best regads,
Dalmiro