Sharepoint 2010 Live to Development VM Copy Setup (backwards deployment) - sharepoint

Live to Development Migration
We are currently migrating some sharepoint sites from external live environments to development environments hosted on vm's. The sites are a mixture of websites and intranets. We have not had access to the live environments so can not specify structure of the sites.
The sites do have some customisations applied. Some are customisations are packaged via wsp packages for which we have the source code (somewhere previous developers have left it need to find it)
The sites setup we have no knowledge so the objective is to restore live back to a development vm so we can bug fix and make enhancements moving forward.
What steps should be go through for this.
We have outlined the following steps:
Take a copy of the content databases/s
Take a copy of the wsp packages straight from the live environment (using powershell)
Create site collections from live on dev
Restore the content databases from live on to these.
Deploy the wsps from live on to dev.
Activate the features from live on our development vm's.
What other steps are missing as I am sure they are.

What I would add here are:
Make sure your notifications don't go to the users of live environment
Make sure your BDC and custom connectivity components don't modify or otherwise load production external data sources
Document and verify (using PowerShell) that all assets are deployed accurately, because sometimes you'll face issues such as event receiver registration, etc.
Make sure your InfoPath forms are reconfigured to use the updated data sources
Make sure your Alternate Access Mappings and Incoming/Outgoing Email settings are adequate

Related

EpiServer content synchronization

I just started working with EPiServer (Sitecore before) and looking for a way how to synchronize content between environments automatically (developer-developer and developer-QA env).
We have our QA environment on an azure virtual machine and need to synchronize content during CI/CD.
EPiServer DXC Service doesn't meet the requirements because we are not working on a web app service.
Any ideas? Is there any already existing way to achieve it?
Automatic synchronization between environments has [more-or-less] gone away within the Episerver platform. The old way of doing this was using mirroring, but that's not available in the DXP, and is eventually being removed from the platform in favor of other strategies:
For moving bulk data (content items, content types, categories, visitor groups, etc.) between different environments, without touching code or the database, use the "Import Data" and "Export Data" tools within Admin mode. More information here: http://webhelp.episerver.com/latest/en/cms-admin/exporting-importing-data.htm
For bigger bulk migrations of data between environments, typically a database backup and restore is done between environments. Obviously, this is a bit more risky when involving a production environment.
If the content (or a content type change) is required as part of a deployment, you can build a content migration step. More information here: https://www.gulla.net/en/blog/renaming-an-episerver-page-property-using-a-migration-step/ and https://world.episerver.com/documentation/developer-guides/CMS/Content/Refactoring-content-type-classes/
If you are simply wanting to move authored content from a staging environment to production, it's suggested to create all content in production and use Episerver's Projects feature. More information here: https://webhelp.episerver.com/latest/en/cms-edit/projects.htm
If you are using Azure DevOps for CI/CD you might want to look into Epinova DXP Extension to Azure DevOps - that uses the Episerver deployment API but makes this easier to set up your pipelines. See https://www.epinova.no/en/folg-med/blog/2020/episerver-dxp-content-harmonization-with-epinova-dxp-deployment/ for more info.
Take a look at the Deployment API. There might be something in there for you. https://world.episerver.com/documentation/developer-guides/digital-experience-platform/deploying/episerver-digital-experience-cloud-deployment-api/

Can I modify an app manifest and re-sign the SharePoint .app file?

I am building a SharePoint 2013 provider-hosted app using the high-trust model. This allows a customer to deploy the .app to their App Catalog and make it available to all SharePoint Sites. The provider-hosted portion of the app runs in an IIS box (cluster) which the customer also deploys (on-premise) with setup instructions and automated tools.
The .app file structure includes the application manifest - which specifies the precise endpoint where the provider-hosted portion resides, and also specifies whitelisted endpoints which the add-in can call. These are all specified by entering in URLs, hostnames, and port numbers into edit fields in Visual Studio in the 'Deploy App' form just before the .app file is built and digitally signed.
This seems to work just fine for a single app built by IT folks internally, if the org is small enough... but I really want to be able to distribute this solution to more than one customer. In order to do so, I would have to ask the customer for their respective endpoints, enter them into my build tools, and rebuild the .app for them. This just doesn't seem right... no customer wants to talk to the developer first and have a custom-built app. And why should they? No code is changing...
Upon investigation into the .app file format, it turns out it is really just a simple .zip file - and inside (voila!) there is the app manifest! Unfortunately, if you edit the app manifest and re-zip the file, the digital signature is broken, and the .app no longer works. (grrrr...)
What I want to do is simply reconfigure the app manifest to match the environment where it is deployed. This can happen programmatically during setup/installation time, or perhaps even just prior to download, but cannot be a process that involves developers typing into visual studio and pressing Rebuild. That simply won't scale.
Is there a tool that exists that can help with this problem? If not, does anyone have experience with the signing of .app files programmatically? I'm open to skinning this cat in any way possible.
This is a wild idea and not maybe even possible.
Create web ui, where clients enter their endpoints.
Have internal process that invokes MSBUILD/TFS to package app with endpoint
change app manifest with pre-build powershell
Then provide app via email or download?
http://www.sharepointconfig.com/2013/10/building-sharepoint-2013-apps-with-tfs-2013/
This is more of a workaround than a true answer - but would work:
For on-premise deployments of high-trust SharePoint 2013 apps - build the application with "known endpoints" - essentially hard-coded endpoints that can be deployed locally. Then instruct the customer to redirect those endpoints using DNS records or hosts file entries. In addition, the client would need to generate a local wildcard certificate signed by their own trusted root in order to satisfy the SharePoint 2013 app model requirements for appdomain and server-to-server communication.
This is by no means ideal, but for certain environments it might be the most practical approach. This also allows scaling for the IIS WebApp to occur at the customer-site, where it realistically belongs for a high-trust app.
This approach avoids the need to automate build tools and also avoids building a separate instance for every customer - both of which are somewhat undesirable. It might, for those reasons, be slightly less costly - but it also pushes some responsibility to the customer. Namely - hard-coding a DNS entry locally for machines in the topology.

Deploying Report(.rdl) and DataSet and Data Source to SharePoint 2013 Integrated mode

I am searching for blog of MSFT article which speaks about publishing/deploying SSRS reports to DEV- QA - Acceptance - PROD SharePoint 2013 in Integrated mode.
Can someone advice if creating a feature/solution and packaging them for deployment is easy way or if there is another way to deploy this reports in the development lifecycle? with every environment(DEV, QA, UAT, PRod) the link within datasource changes which also needs to be dynamic, is it possible?
Within the project properties in SQL Server Data Tools/BIDS, you can define your various environments and enter the appropriate urls for data sources, reports, and server that environment in the deployment properties. Once these are set up, you can choose the correct configuration for the appropriate environment. Then when you click deploy, it will go to the correct location for that environment. Do not be fooled by the Configuration drop-down box on the properties page. You actually have to click the button to switch between configurations.
So change it here:
Not here:
For the data sources, make sure you are using shared data sources and that you set Overwrite data source in your project properties to false. Then update the data source to be appropriate to the environment and deploy it once in each environment. You won't have to do this in the future since it will now be out there. This means your SSRS data source must have the same name in each environment. If you change it in the future, you need to update it and redeploy in each SharePoint environment. Here's a blog post describing this approach.

Best practices for updating SharePoint 2010 production site

I've a VM (#1) with installed SP 2010 and SQL Server 2008. It suites our needs in terms of load and capacity. In case of breaking down we can revert it to the snapshot.
The development process still goes on.
The question is what is good approach for updating the production VM?
Variant 1:
Have a copy of production VM (#2)
When the iteration is finished (development->testing->fixing) and we ready to make update we swap the VMs (#1 <--> #2)
Testing VM #2 becomes production and #1 becomes testing one.
" + " : We go live with fully tested solution.
" - " : Mechanism for sync up between VMs is required.
Variant 2:
Develop, test and fix on the production VM
Publish changes when we are ready.
" + " : We don't need mechanism for sync up between VMs
" - " : Crashes can happen more often.
Any suggestion will be appreciated.
TIA
Do NOT do your development on the production VM. SharePoint is very easy to break during development and you will more than likely bring down your production environment at some point. The risk is basically too high.
Do your development on a separate system. Package your solution/changes properly as a WSP - test it on another system (in between your dev environment, and basically a copy of production). Once it passes all testing on your staging server, deploy the WSP to production.
Swapping systems is a pain in the arse when it comes to SharePoint - you have Alternate Access Mappings, IIS Bindings etc. to worry about - and takes more time and effort than simply just uploading a new WSP and hitting "deploy" (obviously, after testing on your stating server).
It really depends on "what" you are developing:
Content only
It is often easier to do this on the production machine. The standard publishing framework should be sufficent to hide changes from standard users.
Or you could use the content deployment features of sharepoint to move it from the dev farm to the production farm
Or you could use the content deployment tool
Webparts, simple components
In 2010, these should be done as sandboxed solutions (if you can get away with it), then they are very simple to upload/change on your prod environment. Build on your dev enironment, then upload through the sharepoint webpages.
Complex components
Things that require a farm administrator to install on the server (jobs, complex web parts, etc), should be developed with visual studio on your dev box, then moved to prod in a fully tested way. Try having a testing/stage environment.
A combination of all of the above
This usually depends on how much risk your client is willing to expose themselves to, say for instance, if it is a brand new server there is not much risk in taking down users of the system.
I would not recommend installing visual studio on a PRODUCTION SharePoint server

What are the methods for production deployment in SharePoint?

Why does Microsoft suggest using WSPs for production deployment in SharePoint? What are the other methods for production deployment?
WSPs are suggested as they are deployable 'bundles' of functionality, whether that is an Event Handler, Application page or Web Part. By using WSPs you can create and test them in Dev and then roll them out to production once they have been tested. A WSP can be easily managed from the Solution store in Central Administration
It is possible to deploy features by putting the necessary files into the 12 Hive (SharePoint ambiguously named folder), but this requires manual changes to the system. If you have several Web Front Ends (WFEs) in a web farm, then you would need to manually maintain each of them. When using WSPs for deployment, the updates can be deployed to all Servers from one location.
WSP files are designed for deploying functionality to SharePoint in a consistent manner. Although technically they don't do anything you can't do by just copying files to the server, relying on manual deployment is a great way to put the system into an inconsistent state. It may work at first, and even be quicker/easier in some cases, but sooner or later you will permanently break your production environment.
The wsp was specifically designed for the purpose of packaging and deploying SharePoint 2007 solutions. That's why Microsft suggests using it!
While there are a few limitations to it, it's by far the best way to deploy solutions into a prod environment.
You should use WSPs to deploy in SharePoint.
I have used this WSP builder and it's makes your life a little easier.
http://www.codeplex.com/wspbuilder

Resources