Skip to content
Snippets Groups Projects
Commit b31da46f authored by Jose Torres's avatar Jose Torres
Browse files

Adds content for ci and badge

parent 9454700b
No related branches found
No related tags found
1 merge request!2Adds content for ci and badge
Pipeline #
This commit is part of merge request !2. Comments created here will be created in the context of that merge request.
[![build status](https://gitlab.com/gitlab-org/ci-training-slides/badges/master/build.svg)](https://gitlab.com/gitlab-org/ci-training-slides/commits/master)
# CI/CD GitLab Training # CI/CD GitLab Training
   
This project hosts the RevelJS framework and content that renders the CI/CD trainingt slides. Presentation behavior and This project hosts the RevelJS framework and content that renders the CI/CD trainingt slides. Presentation behavior and
Loading
@@ -30,7 +32,7 @@ Content is design to be served in one session of about three or three and a half
Loading
@@ -30,7 +32,7 @@ Content is design to be served in one session of about three or three and a half
### Sample Application ### Sample Application
   
The slides require using a sample CI application which can be found at https://gitlab.com/balameb/ci-training-sample The slides require using a sample CI application which can be found at https://gitlab.com/gitlab-org/ci-training-sample
   
## reveal.js References: ## reveal.js References:
- [Installation](https://github.com/hakimel/reveal.js/#installation): Step-by-step instructions for getting reveal.js - [Installation](https://github.com/hakimel/reveal.js/#installation): Step-by-step instructions for getting reveal.js
Loading
@@ -39,4 +41,4 @@ running on your computer.
Loading
@@ -39,4 +41,4 @@ running on your computer.
fallbacks. fallbacks.
- [Speaker Notes](https://github.com/hakimel/reveal.js/#speaker-notes): Plugin to view speaker notes on a different - [Speaker Notes](https://github.com/hakimel/reveal.js/#speaker-notes): Plugin to view speaker notes on a different
browser window. browser window.
- [PDF Export](https://github.com/hakimel/reveal.js/#pdf-export): Export slides to a PDF. - [PDF Export](https://github.com/hakimel/reveal.js/#pdf-export): Export slides to a PDF.
\ No newline at end of file
## Concepts ## Concepts
   
- *Continouos Integration*: software development practice where code is integrated regularly. - *Continouos Integration*: software development practice where code is
integrated regularly.
- Integration usually includes building and testing - Integration usually includes building and testing
- *Continouos Deployment*: closely related to CI but also implies releasing integrated code into production
- References: - *Continouos Deployment*: closely related to CI but also implies releasing
integrated code into production
- References:
- [Martin Fowler](http://www.martinfowler.com/articles/continuousIntegration.html) - [Martin Fowler](http://www.martinfowler.com/articles/continuousIntegration.html)
- [ThoughtWorks](https://www.thoughtworks.com/continuous-integration) - [ThoughtWorks](https://www.thoughtworks.com/continuous-integration)
- [Agile Alliance](https://www.agilealliance.org/glossary/continuous-integration/) - [Agile Alliance](https://www.agilealliance.org/glossary/continuous-integration/)
## GitLab CI/CD ## GitLab CI/CD
   
- Choose a directory on you machine easy to access - Test result visibility and validation
- Create a workspace or development directory
- This is where we'll be working and adding content - Application Lifecycle
- Continuous Delivery: multiple stages, manual deploys, environments, and
variables
- Open source
Note:
- How does the CI/CD functionality that GitLab offers help the team?
- May be useful to get some ideas about what they are building
   
---------- ----------
   
``` - CI is fully integrated with GitLab
mkdir ~/development
cd ~/development - Scalable: Tests run distributed on separate machines of which you can add as
many as you need
- Jobs run in parallel on multiple machines
   
-or- ![CI Architecture](https://about.gitlab.com/images/ci/arch-1.jpg)
   
mkdir ~/workspace Note:
cd ~/workspace - Mention examples such as building binaries, app packing and delivery, deployment, etc
```
## Workspace ## Runners
   
- Choose a directory on you machine easy to access - Choose a directory on you machine easy to access
- Create a workspace or development directory - Create a workspace or development directory
Loading
Loading
## Sample App ## Sample App
   
- Choose a directory on you machine easy to access
- Create a workspace or development directory
- This is where we'll be working and adding content
   
---------- ----------
   
## Docker
Download and modify a Docker image:
```
docker images
docker run -t -i ruby:2.3 /bin/bash
$ apt-get update
$ apt-get install nodejs -y
$ gem install bundler --no-ri --no-rdoc
# A Dockerfile is a great option for the following line or
# maybe integrate with our current CI script?
$ bundle install
$ exit
# Log back in?
docker ps -a # and get container sha
docker start -i <container-sha>
```
----------
## Create a custom image
docker tag <image id> <url>:<port>/<user/project>:<tag>
``` ```
mkdir ~/development # Commit a new image
cd ~/development docker commit -m "Adds dependencies" -a "Peter Parker" \
<container-sha> registry.gitlab.com/<group-name>/projectname:v2
   
-or- # Login in to GitLab registry
# docker login registry.gitlab.com
docker login <url>:<port>
   
mkdir ~/workspace # Push image to registry
cd ~/workspace # docker push registry.gitlab.com/gitlab-org/ci-training-sample
docker push <registry-url>/<group-name>/<project-name>:<tag>
``` ```
Loading
@@ -33,199 +33,102 @@
Loading
@@ -33,199 +33,102 @@
<script src="lib/js/html5shiv.js"></script> <script src="lib/js/html5shiv.js"></script>
<![endif]--> <![endif]-->
</head> </head>
<body> <body>
<div class="reveal"> <div class="reveal">
<!-- top left GitLab logo -->
<img style="padding: 1em; width: 100px; opacity: 0.5; position: absolute;" src="https://gitlab.com/gitlab-com/gitlab-artwork/raw/master/logo/logo.png"> <img style="padding: 1em; width: 100px; opacity: 0.5; position: absolute;" src="https://gitlab.com/gitlab-com/gitlab-artwork/raw/master/logo/logo.png">
<!-- Any section element inside of this container is displayed as a slide -->
<div class="slides"> <div class="slides">
   
<!-- View presentation notes --> <!-- Main Title -->
<section data-markdown> <section data-markdown>
# GitLab CI/CD # GitLab CI/CD
Training Training
Note:
- Check with the stakeholder if the team is ready
- Make sure to start recording
</section> </section>
   
<section> <!-- Introduction -->
<section> <section data-markdown>
<h2>Agenda</h2> # Introduction
Note:
- Trainer introduction, suggestions:
- Name
- Job role
- Why attedees should spend 3 hrs listening to you
- GitLab introduction
- About GitLab
</section> </section>
<!-- Agenda -->
<section> <section>
<table> <!-- nested agenda sections -->
<thead> <section data-markdown>
<tr> ## Agenda
<th>Sections</th>
</tr> Note:
</thead> - Announce a quick brake after covering the Sample App section
<tbody> - The brake is also for us to make sure attendees have everything
<tr> setup
<td>Introduction</td> - Also announce a Q & A at the end of the session
</tr> </section>
<tr>
<td>Concepts</td> <section data-markdown>
</tr> - Introduction
<tr> - Concepts
<td>Why use CI/CD</td> - Why use CI/CD
</tr> - Sample App
<tr> - CI Setup
<td>Concepts</td> - Runners
</tr> - Questions
<tr> </section>
<td>Sample App</td> </section>
</tr>
<tr> <!-- Concepts -->
<td>CI Setup</td> <section data-markdown="content/concepts.md"
</tr> data-separator="^\n\n\n"
<tr> data-separator-vertical="^----------"
<td>Questions</td> data-separator-notes="^Note:"
</tr> data-charset="iso-8859-15">
</tbody>
</table>
</section> </section>
   
</section> <!-- Why use CI -->
<section data-markdown="content/gitlab_ci.md"
<section data-markdown> data-separator="^\n\n\n"
# Introduction data-separator-vertical="^----------"
</section> data-separator-notes="^Note:"
data-charset="iso-8859-15">
<section data-markdown="content/content.md" </section>
data-separator="^\n\n\n"
data-separator-vertical="^----------" <!-- Sample Application -->
data-separator-notes="^Note:" <section data-markdown="content/sample_app.md"
data-charset="iso-8859-15"> data-separator="^\n\n\n"
</section> data-separator-vertical="^----------"
data-separator-notes="^Note:"
<aside class="notes" data-markdown> data-charset="iso-8859-15">
### CI/CD </section>
sds
</aside> <!-- Why use CI -->
<section data-markdown="content/what_git.md"
<section data-markdown="content/short_story_git.md" data-separator="^\n\n\n"
data-separator="^\n\n\n" data-separator-vertical="^----------"
data-separator-vertical="^----------" data-separator-notes="^Note:"
data-separator-notes="^Note:" data-charset="iso-8859-15">
data-charset="iso-8859-15"> </section>
</section>
<section data-markdown>
<section data-markdown="content/what_git.md" # Questions
data-separator="^\n\n\n"
data-separator-vertical="^----------" Thank you for your hard work!
data-separator-notes="^Note:"
data-charset="iso-8859-15"> Note:
</section> - A hard stop at 30 mins into this section is a good range of time
- Ideally we can also share another channel of sending questions if
<section data-markdown="content/help.md" they have none at the moment
data-separator="^\n\n\n" </section>
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown>
## Git Setup
Workshop Time!
</section>
<section data-markdown="content/install.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown="content/config.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown="content/workspace.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown>
## Git Basics
</section>
<section data-markdown="content/git_workflow.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown="content/gitlab_intro.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown="content/gitlab_git.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown="content/feature_branching.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown="content/merge_requests.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown>
# Merge Conflicts
</section>
<section data-markdown="content/merge_conflicts.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown>
# Revert and Unstage
</section>
<section data-markdown="content/unstage.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown="content/revert.md"
data-separator="^\n\n\n"
data-separator-vertical="^----------"
data-separator-notes="^Note:"
data-charset="iso-8859-15">
</section>
<section data-markdown>
# Questions
Thank you for your hard work!
</section>
   
</div> </div>
   
Loading
Loading
npm-debug.log 0 → 100644
0 info it worked if it ends with ok
1 verbose cli [ '/Users/uno/.nvm/versions/node/v4.2.3/bin/node',
1 verbose cli '/Users/uno/.nvm/versions/node/v4.2.3/bin/npm',
1 verbose cli 'start' ]
2 info using npm@2.14.7
3 info using node@v4.2.3
4 verbose run-script [ 'prestart', 'start', 'poststart' ]
5 info prestart reveal.js@3.2.0
6 info start reveal.js@3.2.0
7 verbose unsafe-perm in lifecycle true
8 info reveal.js@3.2.0 Failed to exec start script
9 verbose stack Error: reveal.js@3.2.0 start: `grunt serve`
9 verbose stack Exit status 1
9 verbose stack at EventEmitter.<anonymous> (/Users/uno/.nvm/versions/node/v4.2.3/lib/node_modules/npm/lib/utils/lifecycle.js:214:16)
9 verbose stack at emitTwo (events.js:87:13)
9 verbose stack at EventEmitter.emit (events.js:172:7)
9 verbose stack at ChildProcess.<anonymous> (/Users/uno/.nvm/versions/node/v4.2.3/lib/node_modules/npm/lib/utils/spawn.js:24:14)
9 verbose stack at emitTwo (events.js:87:13)
9 verbose stack at ChildProcess.emit (events.js:172:7)
9 verbose stack at maybeClose (internal/child_process.js:818:16)
9 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:211:5)
10 verbose pkgid reveal.js@3.2.0
11 verbose cwd /Users/uno/GitLab/ci-training-slides
12 error Darwin 16.1.0
13 error argv "/Users/uno/.nvm/versions/node/v4.2.3/bin/node" "/Users/uno/.nvm/versions/node/v4.2.3/bin/npm" "start"
14 error node v4.2.3
15 error npm v2.14.7
16 error code ELIFECYCLE
17 error reveal.js@3.2.0 start: `grunt serve`
17 error Exit status 1
18 error Failed at the reveal.js@3.2.0 start script 'grunt serve'.
18 error This is most likely a problem with the reveal.js package,
18 error not with npm itself.
18 error Tell the author that this fails on your system:
18 error grunt serve
18 error You can get their info via:
18 error npm owner ls reveal.js
18 error There is likely additional logging output above.
19 verbose exit [ 1, true ]
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment