SlideShare a Scribd company logo
Apply	CI	tools	in	iOS	
development
Khoi	M.	Truong
Innovatube
Strategies
Fastlane
• Automate	tasks
• Pipeline
lane :beta do
increment_build_number
cocoapods
match
testflight sh "./customScript.sh”
slack
end
Why	fastlane?
• One	workflow
Why	fastlane?
• Different	lanes	for	each	strategies
lane :test do
scan
end
lane :beta do
scan
pem
match
gym
pilot
slack
end
Why	fastlane?
• Deploy	from	anywhere	(local,	CI	server,	...)
• Customizable,	easy	to	extend
• Store	everything	in	Git
• Over	170	built-in	integrations	available
• Good	documentations
• …
Fastlane	toolchain
• deliver
• snapshot
• pem
• sigh
• cert
• spaceship
• pilot
• boarding
• gym
• match
• scan
Tech Talk #5 : Apply	CI tools in iOS	development - Trương Minh Khôi
Demo
Install
sudo gem install fastlane -verbose
xcode-select -install
gem cleanup
Init
fastlane init
Commands
fastlane beta
fastlane appstore
fastlane test
Actions
scan
increment_build_number
pem
match
gym
Actions
Additional actions
https://github.com/fastlane/fastlan
e/blob/master/fastlane/docs/Actions
.md
Fastfile
Fastfile
• Ruby
fastlane_version "1.98.0”
default_platform :ios
Fastfile
platform :ios do
# Do something
end
Fastfile
before_all do
ENV["DEVELOPER_DIR"] = "/Applications/Xcode.app"
end
Fastfile
lane :beta do
scan(
scheme: "Beta",
device: "iPhone 6s”
)
end
Fastfile
lane :test do
scan
end
lane :beta do
scan( # Command name
scheme: "Beta", # Parameter
device: "iPhone 6s”
)
end
Appfile
app_identifier "com.khoitm.AlaskaRiver"
apple_id "developer@mail.com"
team_id "ABCD1234”
identifier = CredentialsManager::AppfileConfig.try_fetch_value(:app_identifier)
Static	analysis
brew install swiftlint
# Configurations
.swiftlint.yml
Static	analysis
swiftlint(
mode: :lint,
output_file: 'swiftlint.result.json',
config_file: '.swiftlint.yml',
ignore_exit_status: true
)
• Unit	testing
• Test	report
• Slack	notification
• Scanfile
• Unit	testing
• Run	tests	on	multi-device
• Test	report
• Slack	notification
• Scanfile
• Push	notification	profiles
• Generate
• Maintain
1. Create	Git	repo	to	store	profiles	(certificates,	provisions,	…)
2. Create	private	keys	and	certificates	for	“Distribution”	and	
“Development”.
3. Create	provisioning	profiles	for	targets
• Development
• App	Store
• Ad	hoc
4. Encrypt	certificates	and	provisioning	profiles	with	OpenSSL
5. Access	Git	repo	from	each	machine	to	get	certificates	and	
profiles
6. Config	Xcode	with	profiles
7. Update	profiles	when	add	device	in	Dev	Portal
Tech Talk #5 : Apply	CI tools in iOS	development - Trương Minh Khôi
match(
type: "adhoc",
app_identifier: app_identifier,
git_url: https://some.git/repo/certificates
)
• Build	iOS/macOS	apps
• 30%	faster	than	shenzhen
• Auto-gen	ipa	and	dSYM
• Gymfile
• Archive	accessible	from	Xcode	Organizer
gym(scheme: "Beta")
Tech Talk #5 : Apply	CI tools in iOS	development - Trương Minh Khôi
• Environment	variables
ENV["DEVELOPER_DIR"] = "/Applications/Xcode7.app"
Beta	distribution
crashlytics(
crashlytics_path: './Pods/Crashlytics/',
api_token: 12345678abc',
build_secret: ’987654321edf',
ipa_path: './AlaskaRiver.ipa',
emails: ’tester@mail.com’
)
To-Dos
• Intergrate	with	Jenkin or	Xcode	server
• Upload	screenshots	and	App	info	to	iTunesConnect	
using	deliver and	snapshot
• Notify	beta	testers	and	other	developers	using	slack
• Automate	UI	testing
• Automate	building	with	multi-target:
• Development
• Alpha
• Beta
• Production
Other	tools
• deliver:	Upload	screenshots,	metadata,	and	your	
app	to	the	App	Store
• snapshot:	Automate	taking	localized	screenshots	of	
your	iOS	app	on	every	device
• pilot:	The	best	way	to	manage	your	TestFlight	
testers	and	builds	from	your	terminal
• boarding:	The	easiest	way	to	invite	your	TestFlight	
beta	testers
• spaceship:	Ruby	library	to	access	the	Apple	Dev	
Center	and	iTunes	Connect
Other	tools
• circleci.com
• buddybuild.com
• travis-ci.org
• greenhouseci.com
• Jenkin
Comparations:
http://www.mjdinteractive.com/picking-a-
continuous-integration-platform-for-mobile-projects/
Buddybuild
Buddybuild
Free	100%!
Reference
• https://fastlane.tools/
• https://github.com/fastlane
• https://codesigning.guide/
• https://www.raywenderlich.com/116065/fastlane-
tutorial-getting-started
Thanks	for	listening!

More Related Content

PPT
Tech Talk #5 : CI/CD FOR MOBILE DEVELOPMENT - Đinh Ngọc Kiên
PPTX
Continuos integration with Jenkins for iOS | SuperSpeakers@CodeCamp Iasi, 2014
PPTX
Simple ci cd with strider cd
PDF
QConSP 2014 - Continuous Delivery - Part 03 - Continuous Integration
PPTX
Gitlab CI/CD
PPT
Flash Camp Chennai - Build automation of Flex and AIR applications
PDF
CI/CD 101
PPTX
Automating Your Way to Greatness by Combining OutSystems CI/CD with the Power...
Tech Talk #5 : CI/CD FOR MOBILE DEVELOPMENT - Đinh Ngọc Kiên
Continuos integration with Jenkins for iOS | SuperSpeakers@CodeCamp Iasi, 2014
Simple ci cd with strider cd
QConSP 2014 - Continuous Delivery - Part 03 - Continuous Integration
Gitlab CI/CD
Flash Camp Chennai - Build automation of Flex and AIR applications
CI/CD 101
Automating Your Way to Greatness by Combining OutSystems CI/CD with the Power...

What's hot (20)

PPTX
CI/CD for React Native
PPTX
Salesforce CI (Continuous Integration) - SFDX + Bitbucket Pipelines
PDF
Production Ready WordPress #WPLDN
PPTX
How to Work Efficiently in a Hybrid Git-Perforce Environment
PDF
Trunk based development for Beginners
PDF
Gitlab ci-cd
PDF
Production Ready WordPress - WC Utrecht 2017
PDF
Merge hells!! feature toggles to the rescue
PPTX
The Automated Monolith
PDF
Continuous Delivery @ Codemotion
PPT
Continuous Deployment with Cloud Foundry, Github and Travis CI
ODP
Continuous integration with git lab
PDF
PDF
Magento Continuous Integration & Continuous Delivery @MM17HR
PPTX
dotnetsheff: Continuous delivery with Team City and Octopus Deploy
PPT
CI and CD with Jenkins
PPTX
Michigan IT Symposium 2017 - CI/CD Workflow Tutorial
PDF
Production ready word press
PDF
GitLab - Java User Group
PPTX
Trunk Based Development in the Enterprise - Its Relevance and Economics
CI/CD for React Native
Salesforce CI (Continuous Integration) - SFDX + Bitbucket Pipelines
Production Ready WordPress #WPLDN
How to Work Efficiently in a Hybrid Git-Perforce Environment
Trunk based development for Beginners
Gitlab ci-cd
Production Ready WordPress - WC Utrecht 2017
Merge hells!! feature toggles to the rescue
The Automated Monolith
Continuous Delivery @ Codemotion
Continuous Deployment with Cloud Foundry, Github and Travis CI
Continuous integration with git lab
Magento Continuous Integration & Continuous Delivery @MM17HR
dotnetsheff: Continuous delivery with Team City and Octopus Deploy
CI and CD with Jenkins
Michigan IT Symposium 2017 - CI/CD Workflow Tutorial
Production ready word press
GitLab - Java User Group
Trunk Based Development in the Enterprise - Its Relevance and Economics
Ad

Viewers also liked (20)

PPTX
fastlane x iOSアプリのCI
PDF
LaunchIT #2 - TalentWasabi
PDF
[GeekTalk#2] Takaaki Mizuno - Api Url Design
PPTX
LaunchIT #2 - Etady
PPTX
[GeekTalk#2] Tạ Hoàng Hải - Rest API with PHP
PDF
[INNOVATUBE] How Do An Investor Makes An Investment Decision? - Hajime Hotta
PDF
LaunchIT #2 - WISAMI
PDF
AWS CLI Conference 2016
PPTX
Meet&Greet #1 - Product design for startup
PDF
Amazon Route53へのドメイン移管
PPTX
LaunchIT#1 - ViCare
PPTX
LaunchIT #3 - LocalPrice
PDF
LaunchIT #3 - EnGeek
PDF
LaunchIT #3 - Lily
PPTX
LaunchIT #3 - Readacity
PPTX
iOSアプリ開発のテスト環境 - テストをはじめる最初の一歩 -
PDF
GitHub + Circle CI で幸せになろう
PDF
ポストJenkins時代のCI戦略
PDF
Msa読書会#3前半
PDF
Build an iOS app with ConcourseCI
fastlane x iOSアプリのCI
LaunchIT #2 - TalentWasabi
[GeekTalk#2] Takaaki Mizuno - Api Url Design
LaunchIT #2 - Etady
[GeekTalk#2] Tạ Hoàng Hải - Rest API with PHP
[INNOVATUBE] How Do An Investor Makes An Investment Decision? - Hajime Hotta
LaunchIT #2 - WISAMI
AWS CLI Conference 2016
Meet&Greet #1 - Product design for startup
Amazon Route53へのドメイン移管
LaunchIT#1 - ViCare
LaunchIT #3 - LocalPrice
LaunchIT #3 - EnGeek
LaunchIT #3 - Lily
LaunchIT #3 - Readacity
iOSアプリ開発のテスト環境 - テストをはじめる最初の一歩 -
GitHub + Circle CI で幸せになろう
ポストJenkins時代のCI戦略
Msa読書会#3前半
Build an iOS app with ConcourseCI
Ad

Similar to Tech Talk #5 : Apply CI tools in iOS development - Trương Minh Khôi (20)

PDF
Making the most of your Test Suite
PPTX
Ci of js and apex using jasmine, phantom js and drone io df14
PDF
Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20
PDF
How we realized SOA by Python at PyCon JP 2015
PPTX
Testing API's: Tools & Tips & Tricks (Oh My!)
PDF
[Struyf] Automate Your Tasks With Azure Functions
PDF
Automated Visual Regression Testing by Dave Sadlon
PPTX
Continuous feature-development
PDF
Developing Brilliant and Powerful APIs in Ruby & Python
PDF
Ci for i-os-codemash-01.2013
PPTX
Salesforce_CICD_Overview_Visual By Tushar.pptx
PDF
Infinum Android Talks #13 - Developing Android Apps Like Navy Seals by Ivan Kušt
PDF
2015 jcconf-h2s-devops-practice
PPTX
CI/CD on AWS
PPTX
Splunk: Forward me the REST of those shells
PDF
Exercising and Scaling Up Mobile DevOps in the Enterprise
PPTX
Release Management with Visual Studio Team Services and Office Dev PnP
PDF
August Webinar - Water Cooler Talks: A Look into a Developer's Workbench
PDF
Continuous Integration/Deployment with Docker and Jenkins
PPTX
Cloudstack Continuous Delivery
Making the most of your Test Suite
Ci of js and apex using jasmine, phantom js and drone io df14
Continuous Integration with Open Source Tools - PHPUgFfm 2014-11-20
How we realized SOA by Python at PyCon JP 2015
Testing API's: Tools & Tips & Tricks (Oh My!)
[Struyf] Automate Your Tasks With Azure Functions
Automated Visual Regression Testing by Dave Sadlon
Continuous feature-development
Developing Brilliant and Powerful APIs in Ruby & Python
Ci for i-os-codemash-01.2013
Salesforce_CICD_Overview_Visual By Tushar.pptx
Infinum Android Talks #13 - Developing Android Apps Like Navy Seals by Ivan Kušt
2015 jcconf-h2s-devops-practice
CI/CD on AWS
Splunk: Forward me the REST of those shells
Exercising and Scaling Up Mobile DevOps in the Enterprise
Release Management with Visual Studio Team Services and Office Dev PnP
August Webinar - Water Cooler Talks: A Look into a Developer's Workbench
Continuous Integration/Deployment with Docker and Jenkins
Cloudstack Continuous Delivery

More from Nexus FrontierTech (20)

PPTX
[Executive Lounge Talk] Digital Transformation Journey
PDF
[AI series Talk #2] From PoC to Production - A Case Study
PDF
[AI Series Talk #2] Moving AI from PoC Stage to Production
PDF
[VFS 2019] Introduction to GANs - Pixta Vietnam
PPTX
[VFS 2019] Enabling Young Generation for Future - AWS Vietnam User Group
PPTX
[VFS 2019] Building chatbot with RASA
PPTX
[VFS 2019] Vietnamese Speech-to-Text: Applications and Product
PDF
[VFS 2019] How AI Will Innovate Recruitment
PPTX
[VFS 2019] AI in Finance
PPTX
[VFS 2019] Preventive Approach to Designing and Selling Healthy AI System
PDF
[VFS 2019] Phương pháp phát hiện bất thường bằng học máy
PDF
[VFS 2019] OCR Techniques for Digital Transformation Evolution
PPTX
[VFS 2019] Human Activity Recognition Approaches
PPTX
[VFS 2019] Aimesoft Solutions
PPTX
[VFS 2019] Datamart Introduction (brief)
PDF
[VFS 2019] Data Strategy for Vietnamese Businesses to Levarage AI
PPTX
[VFS 2019] AI for Banks
PDF
[VFS 2019] Digital Solution for Enterprises: 24/7 A.I English Speaking Coach
PDF
[VFS 2019] Project Management for AI-based Product - A Better Approach
PDF
[VFS 2019] AI Ecosystem transition from zero to hero - case study by rubikAI
[Executive Lounge Talk] Digital Transformation Journey
[AI series Talk #2] From PoC to Production - A Case Study
[AI Series Talk #2] Moving AI from PoC Stage to Production
[VFS 2019] Introduction to GANs - Pixta Vietnam
[VFS 2019] Enabling Young Generation for Future - AWS Vietnam User Group
[VFS 2019] Building chatbot with RASA
[VFS 2019] Vietnamese Speech-to-Text: Applications and Product
[VFS 2019] How AI Will Innovate Recruitment
[VFS 2019] AI in Finance
[VFS 2019] Preventive Approach to Designing and Selling Healthy AI System
[VFS 2019] Phương pháp phát hiện bất thường bằng học máy
[VFS 2019] OCR Techniques for Digital Transformation Evolution
[VFS 2019] Human Activity Recognition Approaches
[VFS 2019] Aimesoft Solutions
[VFS 2019] Datamart Introduction (brief)
[VFS 2019] Data Strategy for Vietnamese Businesses to Levarage AI
[VFS 2019] AI for Banks
[VFS 2019] Digital Solution for Enterprises: 24/7 A.I English Speaking Coach
[VFS 2019] Project Management for AI-based Product - A Better Approach
[VFS 2019] AI Ecosystem transition from zero to hero - case study by rubikAI

Recently uploaded (6)

DOC
Camb毕业证学历认证,格罗斯泰斯特主教大学毕业证仿冒文凭毕业证
PPTX
ASMS Telecommunication company Profile
PDF
heheheueueyeyeyegehehehhehshMedia-Literacy.pdf
PDF
6-UseCfgfhgfhgfhgfhgfhfhhaseActivity.pdf
DOC
证书学历UoA毕业证,澳大利亚中汇学院毕业证国外大学毕业证
PDF
Lesson 13- HEREDITY _ pedSAWEREGFVCXZDSASEWFigree.pdf
Camb毕业证学历认证,格罗斯泰斯特主教大学毕业证仿冒文凭毕业证
ASMS Telecommunication company Profile
heheheueueyeyeyegehehehhehshMedia-Literacy.pdf
6-UseCfgfhgfhgfhgfhgfhfhhaseActivity.pdf
证书学历UoA毕业证,澳大利亚中汇学院毕业证国外大学毕业证
Lesson 13- HEREDITY _ pedSAWEREGFVCXZDSASEWFigree.pdf

Tech Talk #5 : Apply CI tools in iOS development - Trương Minh Khôi