<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: mohamed shaban</title>
    <description>The latest articles on DEV Community by mohamed shaban (@mohamed461994).</description>
    <link>https://dev.to/mohamed461994</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F303394%2F5995c24c-a811-49c5-9d9f-b6f6e5320317.jpeg</url>
      <title>DEV Community: mohamed shaban</title>
      <link>https://dev.to/mohamed461994</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mohamed461994"/>
    <language>en</language>
    <item>
      <title>How to automate continues deployment for iOS App using FastLane and GitLab Runner
</title>
      <dc:creator>mohamed shaban</dc:creator>
      <pubDate>Sun, 29 Dec 2019 16:14:03 +0000</pubDate>
      <link>https://dev.to/mohamed461994/how-to-automate-continues-deployment-for-ios-app-using-fastlane-and-gitlab-runner-45o4</link>
      <guid>https://dev.to/mohamed461994/how-to-automate-continues-deployment-for-ios-app-using-fastlane-and-gitlab-runner-45o4</guid>
      <description>&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--rcQ78zZ2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/7jr5vd3z0w2kfbl5c73g.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--rcQ78zZ2--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/7jr5vd3z0w2kfbl5c73g.jpg" alt="Alt Text"&gt;&lt;/a&gt;&lt;br&gt;
First, let’s say we have a &lt;strong&gt;Branch called Staging&lt;/strong&gt; we want to upload a new build to the App Store Connect when code is pushed to &lt;strong&gt;Staging&lt;/strong&gt; Branch.&lt;/p&gt;

&lt;p&gt;You Should First Setup &lt;a href="https://docs.fastlane.tools/getting-started/ios/setup/"&gt;Fastlane&lt;/a&gt; and &lt;a href="https://about.gitlab.com/blog/2016/03/10/setting-up-gitlab-ci-for-ios-projects/"&gt;Gitlab Runner&lt;/a&gt; Then assign that runner to your GitLab Project.&lt;/p&gt;

&lt;p&gt;You Should also &lt;a href="https://docs.fastlane.tools/actions/match/"&gt;Setup Fastlane match&lt;/a&gt; action for ensuring that the app is signed before uploading.&lt;br&gt;
in our &lt;strong&gt;Fast file&lt;/strong&gt;, we will add a lane responsible for archiving and uploading a build to the App Store Connect. This lane takes two parameters target and identifier.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--QMCGO9vS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/0lj93y8po1n94se7gdvb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--QMCGO9vS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/0lj93y8po1n94se7gdvb.png" alt=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;First, we are setting environment variable DELIVER_ITMSTRANSPORTER_ADDITIONAL_UPLOAD_PARAMETERS for fixing Firewall Issues that you may face &lt;a href="https://docs.fastlane.tools/actions/upload_to_app_store/"&gt;More Details&lt;/a&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Then we are building the project and generate IPA using GYM you can &lt;a href="https://docs.fastlane.tools/actions/gym/#gym"&gt;check all its parameters&lt;/a&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Then uploading this IPA using PILOT action you can &lt;a href="https://docs.fastlane.tools/actions/pilot/"&gt;check all its parameters&lt;/a&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;in our .gitlab-ci.yml we will call this lane when code is pushed to Staging Branch&lt;/strong&gt;&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--_ZeW8us9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/6bbpd3sa7h27bvgqglwf.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--_ZeW8us9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/6bbpd3sa7h27bvgqglwf.png" alt=""&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Don’t forget to replace your&lt;/em&gt; &lt;strong&gt;target name&lt;/strong&gt;, your &lt;strong&gt;App ID&lt;/strong&gt; (Bundle ID) &lt;em&gt;and your&lt;/em&gt; &lt;strong&gt;registered runner tag.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Explanation:&lt;/strong&gt; &lt;br&gt;
              &lt;em&gt;we just add one stage for our pipeline it’s called deploy you can add more like a test, lint, build whatever you need to call. Then our deploy stage will run when code only pushed to a branch called staging. our scripts will first run match to ensure Appstore distribution certificates are set. Then we are run the lane that we added to Fast File and passing its parameters.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ios</category>
      <category>devops</category>
    </item>
  </channel>
</rss>
