You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/docs/latest/tutorial/_index.md
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -6,15 +6,15 @@ weight: 2
6
6
7
7
# Introduction
8
8
9
-
This tutorial is a deep dive into some Flatcar fundamental concepts, it is designed to give you the key elements and resources to become autonomous with Flatcar. If you want to have a quickstart, please have a look to the [quickstart guide][quickstart].
9
+
This tutorial is a deep dive into some Flatcar fundamental concepts, it is designed to give you the key elements and resources to become autonomous with Flatcar. If you want to have a quickstart, please have a look to the [Quickstart Guide][quickstart].
10
10
11
11
# Requirements
12
12
13
13
* Linux VM with nested virtualization (or Linux host with KVM)
*`butane` (can be used from the Docker image or [directly from the binary](https://coreos.github.io/butane/getting-started/#getting-butane))
17
+
* OpenStack credentials for the [Hands-on 3](https://www.flatcar.org/docs/latest/tutorial/hands-on-3/)
18
18
19
19
For each covered item, there is a demo and a few lines to explain what's going on under the hood - each item is independent, but it's recommended to follow them in the given order, especially if it is your first time operating Flatcar.
Copy file name to clipboardExpand all lines: content/docs/latest/tutorial/hands-on-2/_index.md
+51-21Lines changed: 51 additions & 21 deletions
Original file line number
Diff line number
Diff line change
@@ -5,47 +5,77 @@ weight: 2
5
5
---
6
6
7
7
The goal of this hands-on is to:
8
-
* provision a local Flatcar instance
9
-
* write Butane configuration
10
-
* generate the Ignition configuration
11
-
* boot the instance with the config
12
8
13
-
This is what we've done in the previous hands-on but now it's done _as code_, we want to deploy an Nginx container serving a "hello world" static webpage. As a reminder, Ignition configuration is used to provision a Flatcar instance, it's JSON file generated from a Butane configuration (YAML).
9
+
* Provision a local Flatcar instance
10
+
* Write Butane configuration
11
+
* Generate the Ignition configuration
12
+
* Boot the instance with the config
13
+
14
+
This is what we've done in the previous hands-on but now it's done _as code_, we want to deploy an Nginx container serving a "hello world" static webpage. As a reminder, Ignition configuration is used to provision a Flatcar instance, it's a JSON file generated from a Butane YAML configuration.
14
15
15
16
# Step-by-step
16
17
17
-
* Clone the tutorial repository and cd into it: `git clone https://github.com/flatcar/flatcar-tutorial ; cd flatcar-tutorial/hands-on-2`
18
-
* Open `./config.yaml` and find the TODO section.
19
-
* Add the following section (from https://coreos.github.io/butane/examples/#files):
Open `./config.yaml`, find the TODO section, and add the following section:
25
+
26
+
```bash
21
27
storage:
22
28
files:
23
29
- path: /var/www/index.html
24
30
contents:
25
31
inline: Hello world
26
32
```
27
-
* Transpile the Butane configuration (`config.yaml`) to Ignition configuration (`config.json`) - it is possible to use the Butane [binary](https://coreos.github.io/butane/getting-started/#standalone-binary) or the Docker image
28
-
```
29
-
$ docker run --rm -i quay.io/coreos/butane:latest < config.yaml > config.json
30
-
```
31
-
* Use a fresh Flatcar image from the previous hands-on (or download again). NOTE: Ignition runs at first boot, it won't work if you reuse your the previously booted image, always decompress again each time you change your Ignition config.
33
+
34
+
**_NOTE_**: More [Butane Config Examples](https://www.flatcar.org/docs/latest/provisioning/config-transpiler/examples/) and [Common Setup, Operations and Customization](https://www.flatcar.org/docs/latest/setup).
35
+
36
+
Transpile the Butane configuration (`config.yaml`) to Ignition configuration (`config.json`) - it is possible to use the Butane [binary](https://coreos.github.io/butane/getting-started/#standalone-binary) or the Docker image
37
+
38
+
```bash
39
+
docker run --rm -i quay.io/coreos/butane:latest < config.yaml > config.json
32
40
```
41
+
42
+
Use a fresh Flatcar image from the previous hands-on (or download again). NOTE: Ignition runs at first boot, it won't work if you reuse the previously booted image, always start from a pristine image.
0 commit comments