View
3
Download
0
Category
Preview:
Citation preview
Copyright©2016Splunk Inc.
GrigoriMelnikandCeceliaCampbellSplunk
SplunkAppLifecycleManagement–withMorePeace,LoveandRock-n-Roll!
Disclaimer
2
Duringthecourseofthispresentation,wemaymakeforwardlookingstatementsregardingfutureeventsortheexpectedperformanceofthecompany.Wecautionyouthatsuchstatementsreflectourcurrentexpectationsandestimatesbasedonfactorscurrentlyknowntousandthatactualeventsorresultscoulddiffermaterially.Forimportantfactorsthatmaycauseactualresultstodifferfromthose
containedinourforward-lookingstatements,pleasereviewourfilingswiththeSEC.Theforward-lookingstatementsmadeinthethispresentationarebeingmadeasofthetimeanddateofitslivepresentation.Ifreviewedafteritslivepresentation,thispresentationmaynotcontaincurrentoraccurateinformation.Wedonotassumeanyobligationtoupdateanyforwardlookingstatementswemaymake.Inaddition,anyinformationaboutourroadmapoutlinesourgeneralproductdirectionandissubjecttochangeatanytimewithoutnotice.Itisforinformationalpurposesonlyandshallnot,beincorporatedintoanycontractorothercommitment.Splunkundertakesnoobligationeithertodevelopthefeaturesor
functionalitydescribedortoincludeanysuchfeatureorfunctionalityinafuturerelease.
3
Asadeveloper,IwanttolowermycostofSplunkappdevelopment– letmefocusonbuildingappswithoutconcerningmyselfaboutthedeploymenttopologiesandthenitty-grittyofthedeploymentprocess.
Asanadmin,Iwanttoeasily&reliablyinstallandmanageanykindofcontent(apps,addons,modules,contentpacks)acrossmyentireSplunkdeployment.
�
�
AppManageability
Copyright © 2016 Splunk Inc. Confidential.
App
Develope
r
TargetedUserFlowSplunk
Admin
Busin
ess
Expe
rt
Develop
Defineappmanifest
Packageappsource
testpackageUpgrade
PUBLISHCERTIFY
DISCOVERACQUIRE
DeployApp/Systemconfiguration
APP
APP APP
re-configure
USE
Copyright © 2016 Splunk Inc. Confidential.
ThepoetryofappmanageabilityNewapppackaging &deployment
tools andguidancefordevelopers andadmins that
simplifyappdeployment and troubleshooting to
distributed environments,whilepreservingappbackward compatibility
withexistingtools&practices.
Copyright © 2016 Splunk Inc. Confidential.
Themechanicsofappmanageability
• Focusondisambiguating config andpartitioning(packaging)relevantpiecesofconfig+code intodeploymentpackages– alongphysical workloadsandlogical groupsofforwarders
Thesystemknows
Copyright © 2016 Splunk Inc. Confidential.
All-in-onetoolforbothdevelopersandadmins
1. Devsuseittodefine andpackage anapp2. Adminsuseittopartition andprepare fordeployment3. Splunkplatform(future)mechanismwilldeploy thepartitionedapp
7
ThePackagingToolkit
Copyright © 2016 Splunk Inc. Confidential.
8
PackagingwithanAppManifest
JSONAPP
dependencies
inputGroups
tasks
platformRequirements
incompatibleApps
optional
info
auto-generated
Copyright © 2016 Splunk Inc. Confidential.
9
PartitioningaPackagedApp
APPPackaging
Toolkit
Copyright © 2016 Splunk Inc. Confidential.
generate-manifest – generateamanifestforanappbasedonitsconfpackage – createasourcepackagewithmanifestpartition – partitionanappintoasetoftargeteddeploymentpackagesdescribe – describeanappconfiguration&dependenciesvalidate – validateanappcontent(incl.appmanifest,packageddependencies,well-formedness)
10
PackagingToolkitCommandsCheatSheet
DevFlowExample
Copyright © 2016 Splunk Inc. Confidential.
12
SampleApp– SplunkAppFor*Nix
APP
TA implieddependencies
task-basedscriptedinputs
possibleplatform-specific
inputsscript://ftr_lookups.py
inputs.confinput://lastlog.shinput://passwd.shinput://version.sh
inputs.conf
SA
Copyright © 2016 Splunk Inc. Confidential.
13
GenerateaManifest$ slim generate-manifest SA_nix –o SA_nix/app.manifestslim generate-manifest: Parsing app configuration at "SA_nix"...slim generate-manifest: Generating app manifest to "SA_nix/app.manifest"...slim generate-manifest: [NOTE] App manifest saved to "SA_nix/app.manifest"
$ slim generate-manifest TA_nix –o TA_nix/app.manifest...
$ slim generate-manifest splunk_app_for_nix –o splunk_app_for_nix/app.manifest...
Copyright © 2016 Splunk Inc. Confidential.
"info": {
"title": "...",
"id": { ... },
"author": { ... },
"releaseDate": "...",
"description": "...",
"license": { ... },
"releaseNotes": { ... }
}
14
AppManifest- info
Copyright © 2016 Splunk Inc. Confidential.
# Define dependencies and versions to enforce
# "dependencies": {
# "<app-id>": {
# "version": "*",
# "package": "<source-package-location>"
# }
# }
#
# Define inputs that are management tasks
# "tasks": []
15
AppManifest- examples# Define custom and dependency input groups
# "inputGroups": {
# "<group-name>": {
# "requires": {
# "<app-id>": ["<input-group-name>"]
# },
# "inputs": ["<defined-inputs>"]
# }
# }
Copyright © 2016 Splunk Inc. Confidential.
"tasks": [
"script://./bin/scripted_inputs/ftr_lookups.py",
]
16
AppManifest– SA_nix
Copyright © 2016 Splunk Inc. Confidential.
"inputGroups": {
"User Monitoring": {
"description": "Monitor current user sessions and login history",
"inputs": ["script://./bin/who.sh", "script://./bin/lastlog.sh”]
},
”OSX Inputs": {
"description": "ES scripted inputs supported on only OSX platforms",
"inputs": ["script://./bin/sshdChecker.sh"]
},
"Linux Inputs": {
"description": "ES scripted inputs supported on Linux platforms",
"inputs": ["script://./bin/selinuxChecker.sh"]
}
}
17
AppManifest– TA_nix
Copyright © 2016 Splunk Inc. Confidential.
"dependencies": {
"SA_nix": {
"version": "~5.2.0",
"package": "SA_nix-5.2.0.tar.gz"
},
"TA_nix": {
"version": "^5.2.0",
"package": "TA_nix-5.2.3.tar.gz"
}
}
18
AppManifest– splunk_app_for_nix
Copyright © 2016 Splunk Inc. Confidential.
19
CreateaSourcePackage$ slim package SA_nixslim package: Packaging app at "SA_nix”...slim package: [NOTE] Source package exported to “SA_nix-5.2.0.tar.gz”
$ slim package TA_nixslim package: Packaging app at "TA_nix”...slim package: [NOTE] Source package exported to “TA_nix-5.2.3.tar.gz”
$ slim package splunk_app_for_nixslim package: Packaging app at "splunk_app_for_nix”...slim package: [NOTE] Source package exported to “splunk_app_for_nix-5.2.0.tar.gz"
Copyright © 2016 Splunk Inc. Confidential.
$ slim describe splunk_app_for_nix-5.2.0.tar.gzslim describe: Describing "splunk_app_for_nix-5.2.0.tar.gz"...[info]|-- The Splunk App for Unix offers new ways to alert, report, and investigate data.| |-- by Splunk, Inc.| |-- defined as splunk_app_for_nix version 5.2.0[input-groups]|-- User Monitoring defines no inputs and requires [TA_nix]|-- Linux Group defines no inputs and requires [TA_nix]|-- SunOS Group defines no inputs and requires [TA_nix]|-- OSX Group defines no inputs and requires [TA_nix][dependency-graph]|-- splunk_app_for_nix@5.2.0| |-- SA_nix@5.2.0 (accepting ~5.2.0)| |-- TA_nix@5.2.3 (accepting ^5.2.0)
20
DescribeanAppPackage
Copyright © 2016 Splunk Inc. Confidential.
21
SampleApp– UpdatedAPP
TA
enforceddependencies
manifest manifesttask-basedscriptedinputs
classified
platform-specificinputsgrouped
TA_nix.tgzSA_nix.tgz
input://taskAinput://taskB
tasksinputGroups
dependencies UserMonitoring: input://lastlog.shLinuxInputs: input://sshdChecker.shOSXInputs: input://update.sh
SA
manifest
Copyright © 2016 Splunk Inc. Confidential.
22
BenefitsforDevsPrevious Method Packaging Toolkit
AppInfo • Scatteredacrossconf • Centralized location• Automaticallygenerated
DependencyManagement • ReleaseNotesrequired• Guessing version
compatibilities
• DefinedandEnforced• SemVer compatible
InputGroups • Allcontent,everywhere • Logicallygrouped
ManagementTasks • Undefined • Treated differently
Copyright © 2016 Splunk Inc. Confidential.
StartonboardingyourappswiththePackagingToolkitGenerateamanifestandcustomizeyourrequirements
Giveusfeedback:AppMgmt-feedback@splunk.com
23
CalltoActionforDevs!
Copyright © 2016 Splunk Inc. Confidential.
24
Butwait,inthefuture…
Copyright © 2016 Splunk Inc. Confidential.
DependenciesareexplicitlydeclaredbytheDevs– Adminscanviewandreconcileappdependenciestoavoidconflicts
automatically
InputsarelogicallygroupedbytheDevs– Adminscantargetspecificlogictotheappropriateworkloads
automatically
Evenwithoutanappmanifest,thePackagingToolkitwillbeabletopartitionbasedonadefaultsetofrules!
25
BenefitsforAdmins
AdminFlowPREVIEW
Copyright © 2016 Splunk Inc. Confidential.
27
Copyright © 2016 Splunk Inc. Confidential.
28
Copyright © 2016 Splunk Inc. Confidential.
29
Copyright © 2016 Splunk Inc. Confidential.
30
Copyright © 2016 Splunk Inc. Confidential.
31
Copyright © 2016 Splunk Inc. Confidential.
32
Copyright © 2016 Splunk Inc. Confidential.
33
Copyright © 2016 Splunk Inc. Confidential.
Appmanageability(installation/uninstallation/update)– Automaticdependencyresolution(cascading)– Mappingoflogicalinputgroupstoserverclasses– Partitioningintotargeteddeploymentpackages
Chooseyourdeploymentmechanism– Now:Chef/Ansible/Puppet/…playbook/recipe/script– Future:AppManagementUI
34
KeyTakeaways
Copyright © 2016 Splunk Inc. Confidential.
DownloadthepublicbetaofthePackagingToolkittoday:http://dev.splunk.com/goto/packaging-toolkitComevisitusattheDev Tools&GuidanceBooth!– LearnMoreandseetheDemos
Giveusfeedback:AppMgmt-feedback@splunk.com
35
What’sNext?
THANKYOU
Recommended