Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sitecore.Ship does not work with Sitecore 8.2 Update 1 for Azure Deployment #66

Open
SC-MNAS opened this issue Dec 27, 2016 · 7 comments

Comments

@SC-MNAS
Copy link

SC-MNAS commented Dec 27, 2016

None of the items gets deployed to Sitecore.
The log below is quiet misleading as looking at this the package should have been installed but actually not.

Sitecore.Ship throws exception here:
var installationInfo = GetInstallationInfo(packagePath);
entries = UpdateHelper.Install(installationInfo, logger, out historyPath); ,<-- silently fails i.e .doesn't return any error and doesn't install package as well.

Logs:
INFO:Installing package: D:\home\site\wwwroot\App_Data\data\temp\d34cb1db-dcef-4dc7-9159-576c2876dfaa.update
INFO:Installation Mode: Install
INFO:Installation of package 'D:\home\site\wwwroot\App_Data\data\temp\d34cb1db-dcef-4dc7-9159-576c2876dfaa.update' has been finished.
INFO:Post installation step for the package 'D:\home\site\wwwroot\App_Data\data\temp\d34cb1db-dcef-4dc7-9159-576c2876dfaa.update' has been executed.

22/12/2016-11:36 PM: Starting PostDeployActions
22/12/2016-11:36 PM: Exception Could not find file 'D:\home\site\wwwroot_DEV\DeployedItems.xml'.(FileNotFoundException):
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize)
at System.Xml.XmlDownloadManager.GetStream(Uri uri, ICredentials credentials, IWebProxy proxy, RequestCachePolicy cachePolicy)
at System.Xml.XmlUrlResolver.GetEntity(Uri absoluteUri, String role, Type ofObjectToReturn)
at System.Xml.XmlTextReaderImpl.FinishInitUriString()
at System.Xml.XmlTextReaderImpl..ctor(String uriStr, XmlReaderSettings settings, XmlParserContext context, XmlResolver uriResolver)
at System.Xml.XmlReaderSettings.CreateReader(String inputUri, XmlParserContext inputContext)
at System.Xml.XmlReader.Create(String inputUri, XmlReaderSettings settings, XmlParserContext inputContext)
at System.Xml.Linq.XElement.Load(String uri, LoadOptions options)
at HedgehogDevelopment.SitecoreProject.PackageInstallPostProcessor.DoPostDeployActions.Run(ITaskOutput output, NameValueCollection metaData)

P.S. On my investigation, I found that Sitecore 8.2 update 1 uses Sitecore.update.dll(version 2.0). UpdateHelper.Install() function has been modified that breaks the package deployment from Sitecore.Ship.

@kevinobee
Copy link
Owner

Thanks for the heads up, will address. Black mark for Sitecore SemVer policy adherence ;-)

@SC-MNAS
Copy link
Author

SC-MNAS commented Dec 27, 2016

For fixing this issue in Sitecore.Ship, possible workaround could be:

Modify 'Sitecore.Ship.Infrastructure.Update.UpdatePackageRunner' class in Sitecore.Ship.Infrastructure project by replacing

entries = UpdateHelper.Install(installationInfo, logger, out historyPath);

with

using (new SecurityDisabler())
{
bool flag;
DiffInstaller installer = new DiffInstaller(installationInfo.Action);
entries = installer.InstallPackage(installationInfo.Path, installationInfo.Mode, logger, new List(), "rollbackPackage.rlb", out flag, ref historyPath);
}

Build the Sitecore.Ship.Infrastructure Project and replace the Sitecore.Ship.Infrastructure.dll in you website.

This will allow to use the simple package installation mode.

@kevinobee
Copy link
Owner

kevinobee commented Dec 27, 2016 via email

dharnitski added a commit to dharnitski/Sitecore.Ship that referenced this issue Jan 4, 2017
@dharnitski
Copy link

dharnitski commented Jan 4, 2017

Pull request submitted - #69

Please let me know if I can do anything else.

@csteeg
Copy link

csteeg commented May 12, 2017

@kevinobee could you please merge this and update the nuget package?

@naveed-ahmad-biz
Copy link

@kevinobee I did the above changes and it worked for me 8.2 update 3

@alexshyba
Copy link

I had a different problem with the Marketplace deployment.
Getting this error during the install:

[ArgumentNullException: Value cannot be null.
Parameter name: path]
   System.IO.File.Delete(String path) +14235104                                Sitecore.Ship.AspNet.Package.InstallUploadPackageCommand.HandleRequest(HttpContextBase context) +593
   Sitecore.Ship.AspNet.Package.InstallPackageCommand.HandleRequest(HttpContextBase context) +280
   Sitecore.Ship.AspNet.AboutCommand.HandleRequest(HttpContextBase context) +399
   Sitecore.Ship.AspNet.BaseHttpHandler.ProcessRequest(HttpContext context) +276
   System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +508
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean&amp; completedSynchronously) +92

To work around, patched the dataFolder variable:

<configuration xmlns:x="http://www.sitecore.net/xmlconfig/">
  <sitecore>
    <sc.variable name="tempFolder">
      <x:attribute name="value">/temp</x:attribute>
    </sc.variable>
  </sitecore>
</configuration>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants