Adam burcher powershell-setupsp_environment-spsbe20
Upcoming SlideShare
Loading in...5
×
 

Adam burcher powershell-setupsp_environment-spsbe20

on

  • 367 views

PowerShell is a key tool for both IT Pros and Developers working in SharePoint. This session will take a look at how PowerShell can be used to managed a farm, right from the start of the farm ...

PowerShell is a key tool for both IT Pros and Developers working in SharePoint. This session will take a look at how PowerShell can be used to managed a farm, right from the start of the farm configuration and all the way through to a working site. The aim is to produce a series of scripts which can be used to automate rolling out a farm, your sites, customisations and content.
This isn’t just for IT Pros, as PowerShell can and should be used by Developers to help with deploying sites and features. A large part of this session will focus on writing custom commands and showing some of the advantages of automating your deployments through scripts.

Statistics

Views

Total Views
367
Views on SlideShare
367
Embed Views
0

Actions

Likes
0
Downloads
4
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Adam burcher powershell-setupsp_environment-spsbe20 Adam burcher powershell-setupsp_environment-spsbe20 Presentation Transcript

  • #SPSBE PowerShell your SharePointenvironment from setup to finish #SPSBE20 Adam Burcher
  • About me• Adam Burcher• http://www.thesharepointbaker.co.uk• #sharepointbaker• ad@thesharepointbaker.co.uk• SharePoint Developer & IT
  • A big thanks to our sponsorsPlatinum SponsorsGold Premium Sponsors Venue SponsorGold Sponsors
  • Agenda• PowerShell – what, why and who?• Out of the Box• Writing custom functions• Demo • Build a SharePoint Farm • Configure a site • Deploy code and then content
  • PowerShell – what?• Scripting language/framework• Configuring Server technologies – SharePoint, Windows, Active Directory, Exchange....• Blurs the lines between scripting (e.g. MS DOS) and code (e.g. C#)
  • PowerShell – why?• Automation – if its scripted, you can run it again• Documented – scripts can form documentation• Simplified rolls outs – scripts do all the work• Distinction between „Code‟, „Content‟ and „Configuration‟ • Code = WSP, C#, DLL • Content & Configuration = PowerShell
  • PowerShell – who?• IT Admins & Dev• One option – IT Admin manage scripts for server, farm and web app setup. Dev everything else.• “Befriend a Dev”• If SharePoint offers collaboration across a business, PowerShell is collaboration between IT Admins and Dev
  • Out of the box• SharePoint comes with a number of very useful cmdlets • New-SPWebApplication • Get-SPSite• Typically you can interchange the „verb‟ – New, Get, Set• Extend by wrapping custom logic – ifs, loops, etc$managedAccount = Get-SPManagedAccount | ?{$_.UserName –eq “tsbappPoolAccount”}if (-not $managedAccount){ New-SPManagedAccount –credientials $credientials}
  • Writing custom scripts• You can write custom cmdlets in code and compile• Custom functions don‟t require “code” (& compiling)• Good news is you can access the SharePoint OM• Bad news is you can access the SharePoint OM• Good C# Code...can make good PowerShell• Bad C# Code...will make bad PowerShell• Treat PowerShell as Production Code
  • The Scripts• Deploy-me.ps1 {args} farmsetup Create the Farm & webapp Central Admin Create our Web App & deploy Site Collection Deploy content Features Deploy Content
  • Demo Building our Farm & Site
  • What‟s next?• Extend scripts for other elements – • Service Applications – search, meta data etc • Other content – new Webs (site hierarchy) • Permissions, users, documents etc• Create EnvVars for UAT, Prod etc• Write a Release Note & Document!• Test Scripts!• Remember, anytime you go to Central Admin or your site to make a change, think – should you script it?
  • Q&A Any questions…?
  • We need your feedback! Scan this QR code or visit http://svy.mk/sps2012be Our sponsors: