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
A Topo Template is a normal project directory. At minimum, it must contain a `compose.yaml` file. Most Templates also include a `Dockerfile` and application source code.
@@ -34,7 +34,6 @@ The directory you create in this section will have the following structure:
34
34
topo-message-card/
35
35
├── compose.yaml
36
36
├── Dockerfile
37
-
├── README.md
38
37
└── src/
39
38
└── index.html
40
39
```
@@ -43,8 +42,7 @@ topo-message-card/
43
42
44
43
Create the application HTML file:
45
44
46
-
```bash
47
-
cat > src/index.html <<'EOF'
45
+
```html
48
46
<!doctype html>
49
47
<htmllang="en">
50
48
<head>
@@ -89,7 +87,6 @@ cat > src/index.html <<'EOF'
89
87
</main>
90
88
</body>
91
89
</html>
92
-
EOF
93
90
```
94
91
95
92
The values wrapped in double braces are placeholders. The `Dockerfile` replaces them with values supplied by Topo.
@@ -98,8 +95,7 @@ The values wrapped in double braces are placeholders. The `Dockerfile` replaces
This file is both a Compose file and a Topo Template definition.
@@ -175,31 +168,6 @@ The `x-topo` section is the Topo metadata block:
175
168
176
169
The argument names in `x-topo.args` match the keys under `services.message-card.build.args`. When Topo resolves the arguments, it writes the selected values into the build arguments.
177
170
178
-
### Add a README
179
-
180
-
Create a short `README.md`:
181
-
182
-
````bash
183
-
cat > README.md <<'EOF'
184
-
# Message Card
185
-
186
-
This project is a Topo Template. It builds a small Nginx web application for
187
-
Arm Linux targets.
188
-
189
-
## Usage
190
-
191
-
```bash
192
-
topo clone dir:/path/to/topo-message-card
193
-
cd topo-message-card
194
-
topo deploy --target localhost
195
-
```
196
-
197
-
Open `http://localhost:8088/` in your browser after deployment.
198
-
EOF
199
-
````
200
-
201
-
The README is not required by the Template format, but it is useful when you share the Template with other users.
202
-
203
171
### Clone the local Template
204
172
205
173
Move to the parent directory and clone your local Template with Topo:
@@ -218,8 +186,6 @@ You can also omit the argument values and answer the interactive prompts:
0 commit comments