Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
CI/CD Con Gitlab
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
David Padilla
June 22, 2017
Technology
140
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
CI/CD Con Gitlab
David Padilla
June 22, 2017
More Decks by David Padilla
See All by David Padilla
Translate Rails apps like a pro
dabit
0
190
Tips and Treats for New Developers
dabit
3
570
Procesando millones de imágenes con Elixir
dabit
0
160
Tus primeros pasos con Elasticsearch
dabit
0
680
Desarrollo Lean: no es un cuento de hadas
dabit
1
110
Web applications with Ruby, not Rails
dabit
1
180
From Rails to the Web Server to The Browser
dabit
2
280
Web Applications With Rails (not Ruby)
dabit
3
230
From Rails to the Webserver to the Browser (Ruby Kaigi)
dabit
2
1.2k
Other Decks in Technology
See All in Technology
現場のトークンマネジメント
dak2
1
200
Zenoh on Zephyr on LiteX
takasehideki
2
130
トークン最適化のためのユーザーストーリー分析 / User Story Analysis for Token Optimization
oomatomo
0
120
千葉での単身赴任からAWSをやり続け、千葉に戻ってきた話
yama3133
1
120
作る力から、見極める力へ — AI時代に広がるエンジニアの価値と役割
rince
0
360
「軸足」は 固定しなくていい - 熱量と強みで描く、しなやかなキャリアの形
kakehashi
PRO
1
280
起点・思考・出力で分解する 〜PM業務の自動化設計〜
kazu_kichi_67
2
1.1k
クレデンシャル流出 ― 攻撃 3 時間 vs 復旧 10 時間。この非対称性にどう備えるか
kazzpapa3
3
610
自分が詳しくない領域でAIを使う #プロヒス2026
konifar
20
7.9k
飲食店もAIで。レジ締めやハンディシステムをつくってる話 / Using AI for restaurant management
vtryo
0
200
AIエージェントとPhysical AIが拓く製造業の変革(ハノーバーメッセリキャップ)
iotcomjpadmin
0
160
[チョークトーク資料]AWS DevOps Agent を使いこなす / AWS Dev Ops Agent Chalk Talk AWS Summit Japan 2026
kinunori
4
800
Featured
See All Featured
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
200
The Pragmatic Product Professional
lauravandoore
37
7.3k
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
350
Site-Speed That Sticks
csswizardry
13
1.2k
SEO Brein meetup: CTRL+C is not how to scale international SEO
lindahogenes
1
2.7k
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.3k
State of Search Keynote: SEO is Dead Long Live SEO
ryanjones
0
210
What the history of the web can teach us about the future of AI
inesmontani
PRO
1
620
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
1
360
Java REST API Framework Comparison - PWX 2021
mraible
34
9.4k
Gemini Prompt Engineering: Practical Techniques for Tangible AI Outcomes
mfonobong
2
450
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
2
580
Transcript
CI/CD con Gitlab David Padilla @dabit
David Padilla @dabit
@micheladaio
CI/CD con Gitlab
CI/CD
Integración Continua CI
Entrega Continua CD
Despliegue Continuo CD
Pruebas Automatizadas
Test Driven Development
Nuestro proceso
Desarrollo Merge Request Peer Review Review QA Staging Más QA
UAT Producción
Desarrollo Merge Request Peer Review Review QA Staging Más QA
UAT Producción
None
Control de versiones (git) Merge Requests / Retroalimentación Orquesta deploys
Corre pruebas Registry de Docker
None
require 'application_system_test_case' class HomepagesTest < ApplicationSystemTestCase test 'homepage' do visit
root_path assert_content 'SGNext' end end
require 'application_system_test_case' class HomepagesTest < ApplicationSystemTestCase test 'homepage' do visit
root_path assert_content 'SGNext' end end
require 'application_system_test_case' class HomepagesTest < ApplicationSystemTestCase test 'homepage' do visit
root_path assert_content 'SGNext' end end
None
None
Como Usuario cuando voy a la pagina principal quiero ver
el slogan "La mejor conferencia de México"
require 'application_system_test_case' class HomepagesTest < ApplicationSystemTestCase test 'homepage' do visit
root_path assert_content 'SGNext' end end
require 'application_system_test_case' class HomepagesTest < ApplicationSystemTestCase test 'homepage' do visit
root_path assert_content 'SGNext' assert_content 'La mejor conferencia de Mexico' end end
None
None
<div class="row align-items-center"> <div class="col-md-12"> <div class="jumbotron"> <h1 class="display-3">SGNext</h1> <p
class="lead"> La mejor conferencia de Mexico </p> </div> </div> </div>
<div class="row align-items-center"> <div class="col-md-12"> <div class="jumbotron"> <h1 class="display-3">SGNext</h1> <p
class="lead"> La mejor conferencia de Mexico </p> </div> </div> </div>
<div class="row align-items-center"> <div class="col-md-12"> <div class="jumbotron"> <h1 class="display-3">SGNext</h1> <p
class="lead"> La mejor conferencia de Mexico </p> </div> </div> </div>
None
None
$ git checkout -b slogan $ git add . $
git commit -m "Nuevo slogan" [slogan d287522] Nuevo slogan 2 files changed, 2 insertions(+)
None
None
None
None
None
None
None
None
None
None
None
require 'application_system_test_case' class HomepagesTest < ApplicationSystemTestCase test 'homepage' do visit
root_path assert_content 'SGNext' assert_content 'La mejor conferencia de México' end end
<div class="row align-items-center"> <div class="col-md-12"> <div class="jumbotron"> <h1 class="display-3">SGNext</h1> <p
class="lead"> La mejor conferencia de México </p> </div> </div> </div>
None
None
None
None
None
None
None
None
None
None
None
None
None
FROM ruby:2.4.1 ENV PHANTOM_JS="phantomjs-2.1.1-linux-x86_64" RUN apt-get update RUN apt-get install
-y software-properties-common apt-transport-https RUN add-apt-repository "deb https://cli-assets.heroku.com/branches/stable/apt ./" RUN curl -L https://cli-assets.heroku.com/apt/release.key | apt-key add - RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - RUN echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - RUN apt-get update && \ apt-get upgrade -y RUN apt-get install -y build-essential chrpath libssl-dev libxft-dev \ libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev qt5-default \ libqt5webkit5-dev gstreamer1.0-plugins-base gstreamer1.0-tools \ gstreamer1.0-x imagemagick cmake yarn nodejs RUN apt-get install heroku RUN gem install dpl RUN curl -L -O https://bitbucket.org/ariya/phantomjs/downloads/$PHANTOM_JS.tar.bz2 RUN tar xvjf $PHANTOM_JS.tar.bz2 && \ mv $PHANTOM_JS /usr/local/share && \ ln -sf /usr/local/share/$PHANTOM_JS/bin/phantomjs /usr/local/bin
FROM ruby:2.4.1 ENV PHANTOM_JS="phantomjs-2.1.1-linux-x86_64" RUN apt-get update RUN apt-get install
-y software-properties-common apt-transport-https RUN add-apt-repository "deb https://cli-assets.heroku.com/branches/stable/apt ./" RUN curl -L https://cli-assets.heroku.com/apt/release.key | apt-key add - RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - RUN echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - RUN apt-get update && \ apt-get upgrade -y RUN apt-get install -y build-essential chrpath libssl-dev libxft-dev \ libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev qt5-default \ libqt5webkit5-dev gstreamer1.0-plugins-base gstreamer1.0-tools \ gstreamer1.0-x imagemagick cmake yarn nodejs RUN apt-get install heroku RUN gem install dpl RUN curl -L -O https://bitbucket.org/ariya/phantomjs/downloads/$PHANTOM_JS.tar.bz2 RUN tar xvjf $PHANTOM_JS.tar.bz2 && \ mv $PHANTOM_JS /usr/local/share && \ ln -sf /usr/local/share/$PHANTOM_JS/bin/phantomjs /usr/local/bin
FROM ruby:2.4.1 ENV PHANTOM_JS="phantomjs-2.1.1-linux-x86_64" RUN apt-get update RUN apt-get install
-y software-properties-common apt-transport-https RUN add-apt-repository "deb https://cli-assets.heroku.com/branches/stable/apt ./" RUN curl -L https://cli-assets.heroku.com/apt/release.key | apt-key add - RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - RUN echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - RUN apt-get update && \ apt-get upgrade -y RUN apt-get install -y build-essential chrpath libssl-dev libxft-dev \ libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev qt5-default \ libqt5webkit5-dev gstreamer1.0-plugins-base gstreamer1.0-tools \ gstreamer1.0-x imagemagick cmake yarn nodejs RUN apt-get install heroku RUN gem install dpl RUN curl -L -O https://bitbucket.org/ariya/phantomjs/downloads/$PHANTOM_JS.tar.bz2 RUN tar xvjf $PHANTOM_JS.tar.bz2 && \ mv $PHANTOM_JS /usr/local/share && \ ln -sf /usr/local/share/$PHANTOM_JS/bin/phantomjs /usr/local/bin
FROM ruby:2.4.1 ENV PHANTOM_JS="phantomjs-2.1.1-linux-x86_64" RUN apt-get update RUN apt-get install
-y software-properties-common apt-transport-https RUN add-apt-repository "deb https://cli-assets.heroku.com/branches/stable/apt ./" RUN curl -L https://cli-assets.heroku.com/apt/release.key | apt-key add - RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - RUN echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - RUN apt-get update && \ apt-get upgrade -y RUN apt-get install -y build-essential chrpath libssl-dev libxft-dev \ libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev qt5-default \ libqt5webkit5-dev gstreamer1.0-plugins-base gstreamer1.0-tools \ gstreamer1.0-x imagemagick cmake yarn nodejs RUN apt-get install heroku RUN gem install dpl RUN curl -L -O https://bitbucket.org/ariya/phantomjs/downloads/$PHANTOM_JS.tar.bz2 RUN tar xvjf $PHANTOM_JS.tar.bz2 && \ mv $PHANTOM_JS /usr/local/share && \ ln -sf /usr/local/share/$PHANTOM_JS/bin/phantomjs /usr/local/bin
None
.gitlab-ci.yml
image: registry.michelada.io/demos/sgnext/image services: - postgres stages: - test - review
- staging - production variables: DISABLE_SPRING: 'true' before_script: - gem install bundler --no-ri --no-rdoc - rm -rf vendor/ruby/2.4.0/cache/bundler/git || true - ruby -v cache: paths: - vendor/ruby - node_modules build: stage: test script: - bundle install -j $(nproc) --path vendor --full-index --clean - bin/yarn - cp config/database.ci.yml config/database.yml - bundle exec rails db:create RAILS_ENV=test - bundle exec rails db:test:prepare RAILS_ENV=test - bundle exec rails test - bundle exec rails test:system deploy_review: stage: review script: - gem install dpl - heroku apps:fork --from $HEROKU_STAGING_APP --to $CI_ENVIRONMENT_SLUG || true - dpl --provider=heroku --app=$CI_ENVIRONMENT_SLUG --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$CI_ENVIRONMENT_SLUG environment: name: review/$CI_BUILD_REF_NAME url: https://$CI_ENVIRONMENT_SLUG.herokuapp.com only: - branches except: - master staging: stage: staging environment: staging script: - gem install dpl - dpl --provider=heroku --app=$HEROKU_STAGING_APP --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$HEROKU_STAGING_APP only: - master production: stage: production environment: production script: - gem install dpl - dpl --provider=heroku --app=$HEROKU_PROD_APP --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$HEROKU_PROD_APP only: - master when: manual
image: registry.michelada.io/demos/sgnext/image services: - postgres stages: - test - review
- staging - production variables: DISABLE_SPRING: 'true' before_script: - gem install bundler --no-ri --no-rdoc - rm -rf vendor/ruby/2.4.0/cache/bundler/git || true - ruby -v cache: paths: - vendor/ruby - node_modules build: stage: test script:
image: registry.michelada.io/demos/sgnext/image services: - postgres stages: - test - review
- staging - production variables: DISABLE_SPRING: 'true' before_script: - gem install bundler --no-ri --no-rdoc - rm -rf vendor/ruby/2.4.0/cache/bundler/git || true - ruby -v cache: paths: - vendor/ruby - node_modules build: stage: test script:
image: registry.michelada.io/demos/sgnext/image services: - postgres stages: - test - review
- staging - production variables: DISABLE_SPRING: 'true' before_script: - gem install bundler --no-ri --no-rdoc - rm -rf vendor/ruby/2.4.0/cache/bundler/git || true - ruby -v cache: paths: - vendor/ruby - node_modules build: stage: test script:
image: registry.michelada.io/demos/sgnext/image services: - postgres stages: - test - review
- staging - production variables: DISABLE_SPRING: 'true' before_script: - gem install bundler --no-ri --no-rdoc - rm -rf vendor/ruby/2.4.0/cache/bundler/git || true - ruby -v cache: paths: - vendor/ruby - node_modules build: stage: test script:
- gem install bundler --no-ri --no-rdoc - rm -rf vendor/ruby/2.4.0/cache/bundler/git
|| true - ruby -v cache: paths: - vendor/ruby - node_modules build: stage: test script: - bundle install -j $(nproc) --path vendor --full-index --clean - bin/yarn - cp config/database.ci.yml config/database.yml - bundle exec rails db:create RAILS_ENV=test - bundle exec rails db:test:prepare RAILS_ENV=test - bundle exec rails test - bundle exec rails test:system deploy_review: stage: review script: - gem install dpl - heroku apps:fork --from $HEROKU_STAGING_APP --to $CI_ENVIRONMENT_SLUG || true - dpl --provider=heroku --app=$CI_ENVIRONMENT_SLUG --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$CI_ENVIRONMENT_SLUG environment: name: review/$CI_BUILD_REF_NAME url: https://$CI_ENVIRONMENT_SLUG.herokuapp.com
- gem install bundler --no-ri --no-rdoc - rm -rf vendor/ruby/2.4.0/cache/bundler/git
|| true - ruby -v cache: paths: - vendor/ruby - node_modules build: stage: test script: - bundle install -j $(nproc) --path vendor --full-index --clean - bin/yarn - cp config/database.ci.yml config/database.yml - bundle exec rails db:create RAILS_ENV=test - bundle exec rails db:test:prepare RAILS_ENV=test - bundle exec rails test - bundle exec rails test:system deploy_review: stage: review script: - gem install dpl - heroku apps:fork --from $HEROKU_STAGING_APP --to $CI_ENVIRONMENT_SLUG || true - dpl --provider=heroku --app=$CI_ENVIRONMENT_SLUG --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$CI_ENVIRONMENT_SLUG environment: name: review/$CI_BUILD_REF_NAME url: https://$CI_ENVIRONMENT_SLUG.herokuapp.com
staging: stage: staging environment: staging script: - gem install dpl
- dpl --provider=heroku --app=$HEROKU_STAGING_APP --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$HEROKU_STAGING_APP only: - master production: stage: production environment: production script: - gem install dpl - dpl --provider=heroku --app=$HEROKU_PROD_APP --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$HEROKU_PROD_APP only: - master when: manual rubocop: stage: test script: - bundle install -j $(nproc) --path vendor - bundle exec rubocop
staging: stage: staging environment: staging script: - gem install dpl
- dpl --provider=heroku --app=$HEROKU_STAGING_APP --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$HEROKU_STAGING_APP only: - master production: stage: production environment: production script: - gem install dpl - dpl --provider=heroku --app=$HEROKU_PROD_APP --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$HEROKU_PROD_APP only: - master when: manual rubocop: stage: test script: - bundle install -j $(nproc) --path vendor - bundle exec rubocop
Agnóstico
- gem install bundler --no-ri --no-rdoc - rm -rf vendor/ruby/2.4.0/cache/bundler/git
|| true - ruby -v cache: paths: - vendor/ruby - node_modules build: stage: test script: - bundle install -j $(nproc) --path vendor --full-index --clean - bin/yarn - cp config/database.ci.yml config/database.yml - bundle exec rails db:create RAILS_ENV=test - bundle exec rails db:test:prepare RAILS_ENV=test - bundle exec rails test - bundle exec rails test:system deploy_review: stage: review script: - gem install dpl - heroku apps:fork --from $HEROKU_STAGING_APP --to $CI_ENVIRONMENT_SLUG || true - dpl --provider=heroku --app=$CI_ENVIRONMENT_SLUG --api-key=$HEROKU_API_KEY - heroku run rake db:migrate --app=$CI_ENVIRONMENT_SLUG environment: name: review/$CI_BUILD_REF_NAME url: https://$CI_ENVIRONMENT_SLUG.herokuapp.com
iOS build_project: stage: build script: - xcodebuild clean -project ProjectName.xcodeproj
-scheme SchemeName | xcpretty - xcodebuild test -project ProjectName.xcodeproj -scheme SchemeName -destination 'platform=iOS Simulator,name=iPhone 6s,OS=9.2' | xcpretty -s
php image: php:5.6 before_script: # Install dependencies - bash ci/docker_install.sh
> /dev/null test:app: script: - phpunit --configuration phpunit_myapp.xml
Instalación
gitlab.com
None
None
None
TATFT
Prueba todo el bendito tiempo
Gracias @dabit