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
Automation using Gitlab CI and Docker, DevHeave...
Search
Ondrej Sika
April 21, 2018
Programming
0
200
Automation using Gitlab CI and Docker, DevHeaven 2018
https://ondrej-sika.cz/blog/2018/talk-automatizace-pomoci-gitlab-ci-a-dockeru/
Ondrej Sika
April 21, 2018
Tweet
Share
More Decks by Ondrej Sika
See All by Ondrej Sika
ZEIT, Serverless Deployments
ondrejsika
0
66
Introduction to Docker & Kubernetes @ JavaDays 2019
ondrejsika
1
230
Terraform - Infrastructure as a Code
ondrejsika
1
220
Gitlab CI + Docker (LinuxDays 2018)
ondrejsika
2
250
TechEd 2018, Introduction to Docker
ondrejsika
0
500
Lightning Network aneb Bitcoin 2.0, Plzensky Barcamp, 7.4.2018
ondrejsika
0
96
Python Libraries for Bitcoin and Ethereum, PyCon SK 2018
ondrejsika
1
140
i3 tiling window manager, Install Fest 2018
ondrejsika
1
310
Docker, Zlin, 8. 2. 2018
ondrejsika
0
100
Other Decks in Programming
See All in Programming
Cursor/Devin全社導入の理想と現実
saitoryc
28
21k
インプロセスQAにおいて大事にしていること / In-process QA Meetup
medley
0
140
ニーリーQAのこれまでとこれから
nealle
2
160
Serving TUIs over SSH with Go
caarlos0
0
580
2ヶ月で生産性2倍、お買い物アプリ「カウシェ」4チーム同時改善の取り組み
ike002jp
1
110
サービスレベルを管理してアジャイルを加速しよう!! / slm-accelerate-agility
tomoyakitaura
1
200
fieldalignmentから見るGoの構造体
kuro_kurorrr
0
130
KANNA Android の技術的課題と取り組み
watabee
0
190
Improve my own Ruby
sisshiki1969
0
100
Beyond_the_Prompt__Evaluating__Testing__and_Securing_LLM_Applications.pdf
meteatamel
0
110
The Nature of Complexity in John Ousterhout’s Philosophy of Software Design
philipschwarz
PRO
0
160
監視 やばい
syossan27
12
10k
Featured
See All Featured
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
34
2.9k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
PRO
19
1.2k
Thoughts on Productivity
jonyablonski
69
4.6k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
12k
Why You Should Never Use an ORM
jnunemaker
PRO
56
9.3k
[RailsConf 2023] Rails as a piece of cake
palkan
54
5.5k
Being A Developer After 40
akosma
91
590k
BBQ
matthewcrist
88
9.6k
KATA
mclloyd
29
14k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
47
2.7k
Six Lessons from altMBA
skipperchong
28
3.7k
Unsuck your backbone
ammeep
671
57k
Transcript
Automation using Gitlab CI and Docker Ondrej Sika ondrej@ondrejsika.com DevHeaven,
Pilsen CZ, 21. 4. 2018
Goals - Build application - Auto deploy to test -
Manual deploy to production
None
Tools - Git - Gitlab + Gitlab CI - Docker
- Traefik
Setup CI environment
Gitlab CI Runner docker-machine create runner eval $(docker-machine env runner)
git clone git@github.com:ondrejsika/gitlab-ci-runner.git cd gitlab-ci-runner ./create-runner.sh ./register-runner.sh GITLAB_CI_TOKEN
Server
Traefik Proxy git clone git@github.com:ondrejsika/traefik-ssl.git cd traefik-ssl # put SSL
cert.pem and key.pem to certs/ dit docker-compose up -d
Gitlab
Gitlab - Create Gitlab project - Setup CI sercret variables
- SSLPASS (password to server which runs the app)
Application
Application - Dockerize project - Add .gitlab-ci.yml (CI config)
Clone Jekyll Website git clone git@github.com:ondrejsika/jekyll-demo.git cd jekyll-demo git remote
rename origin github git remote add origin git@gitlab.sikahq.com:test/jekyll.git git push origin master -u
Dockerize git reset --hard github/docker cat Dockerfile
Add Gitlab CI configuration git reset --hard github/gitlab-ci cat .gitlab-ci.yml
Push & some magic hapens
Push git push origin master -u
Make some changes git checkout -b awesome-header vim index.md git
commit -am 'make header awesome' git push origin awesome-header -u
Resources - https://github.com/ondrejsika/jekyll-demo - https://github.com/ondrejsika/traefik-ssl - https://github.com/ondrejsika/gitlab-ci-runner - https://github.com/ondrejsika/ondrejsika-ci-docker -
https://traefik.io/
Thank you & Questions Ondrej Sika email: ondrej@ondrejsika.com web: ondrej-sika.cz
twitter: @ondrejsika linkedin: /in/ondrejsika/ Slides: https://sika.link/devheaven2018