Skip to content

Commit 9622b23

Browse files
authored
docs: improve cdn migration info (#5719)
1 parent a52c15c commit 9622b23

File tree

26 files changed

+81
-73
lines changed

26 files changed

+81
-73
lines changed

docker-compose.yml

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ services:
5353
sh -c "
5454
/app/cds-engine-linux-amd64 config new > /app/conf/conf.toml;
5555
mkdir -p /app/artifacts /app/repositories /app/hatchery-local;
56-
chown -R cds:cds /app/conf /app/artifacts /app/repositories /app/hatchery-local;
56+
chown -R cds:cds /app/conf /app/artifacts /app/repositories /app/hatchery-local /app/cdn-buffer /app/cdn-storage;
5757
/app/cds-engine-linux-amd64 config edit /app/conf/conf.toml --output /app/conf/conf.toml \
5858
api.artifact.local.baseDirectory=/app/artifacts \
5959
api.cache.redis.host=cds-cache:6379 \
@@ -68,8 +68,13 @@ services:
6868
api.smtp.host=smtpmocksrv \
6969
cdn.cache.redis.host=cds-cache:6379 \
7070
cdn.cache.redis.password=cds \
71+
cdn.storageUnits.buffers.redis.redis.host=cds-cache:6379 \
72+
cdn.storageUnits.buffers.redis.redis.password=cds \
73+
cdn.storageUnits.buffers.local-buffer.local.path=/app/cdn-buffer \
74+
cdn.storageUnits.storages.local.local.path=/app/cdn-storage \
75+
cdn.storageUnits.storages.cds.cds.host=http://cds-api:8081 \
7176
cdn.database.host=cds-db \
72-
cdn.publicTCP=cds-cdn:8090 \
77+
cdn.publicTCP=${HOSTNAME}:8090 \
7378
cdn.api.http.url=http://cds-api:8081 \
7479
cdn.url=http://cds-cdn:8089 \
7580
hatchery.local.commonConfiguration.url=http://cds-hatchery-local:8086 \
@@ -101,7 +106,8 @@ services:
101106
elasticsearch.elasticsearch.url=http://elasticsearch:9200 \
102107
ui.url=http://${HOSTNAME}:8080 \
103108
ui.api.http.url=http://cds-api:8081 \
104-
ui.hooksURL=http://cds-hooks:8083;
109+
ui.hooksURL=http://cds-hooks:8083 \
110+
ui.cdnURL=http://cds-cdn:8089;
105111
echo '';
106112
echo '/!\ Please run the export command BELOW, this will be useful to create admin user';
107113
echo '';
@@ -116,6 +122,8 @@ services:
116122
- cds-artifacts-volume:/app/artifacts
117123
- cds-repositories-volume:/app/repositories
118124
- cds-hatchery-local-volume:/app/hatchery-local
125+
- cds-cdn-buffer-volume:/app/cdn-buffer
126+
- cds-cdn-storage-volume:/app/cdn-storage
119127

120128
cds-api:
121129
image: ${CDS_DOCKER_IMAGE:-ovhcom/cds-engine:latest}
@@ -144,6 +152,7 @@ services:
144152
links:
145153
- cds-api
146154
- cds-hooks
155+
- cds-cdn
147156
healthcheck:
148157
test: ["CMD", "curl", "-f", "http://127.0.0.1:8080/mon/version"]
149158
interval: 30s
@@ -166,12 +175,15 @@ services:
166175
command: sh -c "/app/cds-engine-linux-amd64 start cdn --config /app/conf/conf.toml"
167176
volumes:
168177
- cds-conf-volume:/app/conf
178+
- cds-cdn-buffer-volume:/app/cdn-buffer
179+
- cds-cdn-storage-volume:/app/cdn-storage
169180
ports:
170181
- "8089:8089"
171182
- "8090:8090"
172183
links:
173184
- cds-db
174185
- cds-cache
186+
- cds-api
175187
healthcheck:
176188
test: ["CMD", "curl", "-f", "http://127.0.0.1:8089/mon/version"]
177189
interval: 30s
@@ -290,3 +302,5 @@ volumes:
290302
cds-hatchery-local-volume:
291303
cds-conf-volume:
292304
cds-elasticsearch-volume:
305+
cds-cdn-buffer-volume:
306+
cds-cdn-storage-volume:

docs/README.md

Lines changed: 0 additions & 1 deletion
This file was deleted.

docs/assets/sass/_base.sass

Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ header
226226
transform: translate(-50%, -50%)
227227
display: block
228228
width: 45px
229-
height: 44px
229+
height: 44px
230230

231231
#mainNav
232232
h5
@@ -299,7 +299,7 @@ ul.global-nav
299299
left: 10px;
300300
top: 10px;
301301
font-size: 2.25rem
302-
302+
303303

304304
#hero
305305
background-color: $dark-grey
@@ -352,7 +352,7 @@ section
352352
margin-right: 30px
353353

354354
.fa-search
355-
cursor: pointer
355+
cursor: pointer
356356

357357
#search-query
358358
background-color: transparent
@@ -369,7 +369,7 @@ section
369369
&:focus
370370
background-color: $light-grey
371371
color: $dark-grey
372-
372+
373373
#hero
374374
background-color: $dark-grey
375375

@@ -411,7 +411,7 @@ section
411411

412412
#page-content
413413
.asciinema-terminal .line span
414-
font-family: Consolas, Menlo, 'Bitstream Vera Sans Mono', monospace, 'Powerline Symbols'
414+
font-family: Consolas, Menlo, 'Bitstream Vera Sans Mono', monospace, 'Powerline Symbols'
415415

416416
#page-content-with-menu
417417
position: relative
@@ -564,8 +564,6 @@ dd
564564
code
565565
display: inline-block
566566
box-sizing: border-box
567-
background-color: $light-grey
568-
color: $dark-grey
569567
font-family: 'Open Sans Mono', monospace
570568
vertical-align: baseline
571569
font-size: 14px
@@ -583,9 +581,6 @@ dd
583581
.highlight code span, code, pre code
584582
font-family: "Open Sans Mono", monospace
585583

586-
code, pre code
587-
color: #303030
588-
589584
pre code
590585
padding: 0
591586

@@ -597,7 +592,6 @@ dd
597592
background-color: #121314!important
598593

599594
pre
600-
background-color: #f7f7f7
601595
display: block
602596
margin: 20px 0
603597
padding: 15px
@@ -783,14 +777,14 @@ $feature-box-div-margin-bottom: 40px
783777
background-color: #92c455
784778
padding-top: 70px
785779
padding-bottom: 100px
786-
780+
787781
div
788782
display: inline-block
789783
color: #fff
790784
vertical-align: top
791785
width: 100%
792786
text-align: center
793-
787+
794788
h2
795789
color: black
796790
text-align: center
@@ -801,7 +795,7 @@ $feature-box-div-margin-bottom: 40px
801795
background-color: #fff
802796
padding-bottom: 20px
803797
text-align: center
804-
798+
805799
.section-text
806800
width: 100%
807801
padding-right: 10%
@@ -810,11 +804,11 @@ $feature-box-div-margin-bottom: 40px
810804
color: black
811805
text-align: center
812806
padding-bottom: 0px
813-
807+
814808
.player
815809
width: 100%
816810
max-width: 100%
817-
811+
818812

819813
div
820814
display: grid
@@ -843,7 +837,7 @@ $feature-box-div-margin-bottom: 40px
843837

844838
tr:nth-child(odd)
845839
background-color: #e882a8
846-
840+
847841
tr:nth-child(even)
848842
background-color: #e882a8
849843

@@ -853,7 +847,7 @@ $feature-box-div-margin-bottom: 40px
853847
text-align: center
854848
border-bottom: 1px solid
855849
border-bottom-color: #de3e7b
856-
850+
857851
.fa-times
858852
font-size: 1rem
859853
color: #eee
@@ -873,12 +867,12 @@ $feature-box-div-margin-bottom: 40px
873867
margin-left: 5px
874868
a
875869
text-decoration: none
876-
870+
877871
a
878872
font-size: 0.5rem
879873
color: #eee
880874
text-decoration: underline
881-
875+
882876

883877
.page
884878
display: flex

docs/content/development/contribute/documentation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ card:
55
name: contribute
66
---
77

8-
Documentation https://ovh.github.io/cds is generated with Hugo. Source are under https://github.com/ovh/cds/tree/{{< param "version" >}}/docs/content
8+
Documentation https://ovh.github.io/cds is generated with Hugo. Source are under https://github.com/ovh/cds/tree/{{< param "version" "master" >}}/docs/content
99

1010
Write / Generate / Test documentation:
1111

docs/content/development/contribute/hatchery.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@ card:
99

1010
* First of all you need to create a new package like the other into the hatchery package. Let's call this package vSphere for our example.
1111

12-
* You have to implement the Service interface (see [here](https://github.com/ovh/cds/blob/{{< param "version" >}}/engine/types.go)) in order to configure launch this new hatchery mode via CDS engine CLI.
12+
* You have to implement the Service interface (see [here](https://github.com/ovh/cds/blob/{{< param "version" "master" >}}/engine/types.go)) in order to configure launch this new hatchery mode via CDS engine CLI.
1313

14-
* Your have to create a Configuration structure composed of the [hatchery.CommonConfiguration](https://godoc.org/github.com/ovh/cds/sdk/hatchery#CommonConfiguration) and the variables you need to access to vSphere API. You finally have to update the [engine main.go file](https://github.com/ovh/cds/blob/{{< param "version" >}}/engine/main.go) to manage this new service and add and manage the configuration structure as part of the [global configuration](https://github.com/ovh/cds/blob/{{< param "version" >}}/engine/types.go).
14+
* Your have to create a Configuration structure composed of the [hatchery.CommonConfiguration](https://godoc.org/github.com/ovh/cds/sdk/hatchery#CommonConfiguration) and the variables you need to access to vSphere API. You finally have to update the [engine main.go file](https://github.com/ovh/cds/blob/{{< param "version" "master" >}}/engine/main.go) to manage this new service and add and manage the configuration structure as part of the [global configuration](https://github.com/ovh/cds/blob/{{< param "version" "master" >}}/engine/types.go).
1515

1616
* You need to implement the hatchery interface (see [here](https://godoc.org/github.com/ovh/cds/sdk/hatchery#Interface))
1717

docs/content/development/contribute/plugin.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@ A CDS worker executes job, and job is composed of steps.
99

1010
A step is an [action]({{< relref "/docs/actions/_index.md" >}})
1111

12-
A Plugin is simply an executable which expose a GRPC server corresponding to the right [proto file](https://github.com/ovh/cds/tree/{{< param "version" >}}/sdk/grpcplugin/actionplugin/actionplugin.proto). You can use the programming language of your choice. The CDS worker will simply query the GRPC server of the plugin.
12+
A Plugin is simply an executable which expose a GRPC server corresponding to the right [proto file](https://github.com/ovh/cds/tree/{{< param "version" "master" >}}/sdk/grpcplugin/actionplugin/actionplugin.proto). You can use the programming language of your choice. The CDS worker will simply query the GRPC server of the plugin.
1313

1414
In order to communicate with a CDS worker, a plugin MUST fill the following requirements:
1515

1616
+ Expose a GRPC server
17-
+ Implement methods and messages coming from this [proto file](https://github.com/ovh/cds/tree/{{< param "version" >}}/sdk/grpcplugin/actionplugin/actionplugin.proto)
17+
+ Implement methods and messages coming from this [proto file](https://github.com/ovh/cds/tree/{{< param "version" "master" >}}/sdk/grpcplugin/actionplugin/actionplugin.proto)
1818
+ Display this message at the launch of your plugin XXX is ready to accept new connection where XXX is your ip address with port or your Unix socket (example: `127.0.0.1:55939 is ready to accept new connection` or for a Unix socket `XXX.sock is ready to accept new connection`). Note that your plugin can use any Unix socket or tcp port as long as it informs the worker using the log line above.
1919

20-
More resources that may help you in developing a CDS plugin are available: [SDK in this directory](https://github.com/ovh/cds/tree/{{< param "version" >}}/sdk/grpcplugin/actionplugin) with some examples [here](https://github.com/ovh/cds/tree/{{< param "version" >}}/contrib/grpcplugins/action/examples).
20+
More resources that may help you in developing a CDS plugin are available: [SDK in this directory](https://github.com/ovh/cds/tree/{{< param "version" "master" >}}/sdk/grpcplugin/actionplugin) with some examples [here](https://github.com/ovh/cds/tree/{{< param "version" "master" >}}/contrib/grpcplugins/action/examples).
2121

22-
Contribute on https://github.com/ovh/cds/tree/master/contrib/grpcplugins/action
22+
Contribute on https://github.com/ovh/cds/tree/{{< param "version" "master" >}}/contrib/grpcplugins/action

docs/content/docs/components/_index.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,16 +15,16 @@ cards:
1515
description: "The most powerful Command Line for a CI/CD Platform. cdsctl is the CDS Command Line - you can script everything with it, cdsctl also provide some cool commands such as cdsctl shell to browse your projects and workflows without the need to open a browser."
1616
button: "cdsctl reference"
1717
button_path: "/docs/components/cdsctl"
18-
- name: worker
19-
title: "CDS Worker"
20-
description: "A pipeline is structured in sequential stages containing one or multiple concurrent jobs. A Job will be executed by a worker. The binary worker is available from CDS Job"
21-
button: "worker reference"
22-
button_path: "/docs/components/worker"
2318
- name: hatchery
2419
title: "Hatchery"
2520
description: "Hatchery is a service dedicated to spawn and kill worker in accordance with build queue needs."
2621
button: "Discover the Hatchery component"
2722
button_path: "/docs/components/hatchery"
23+
- name: worker
24+
title: "CDS Worker"
25+
description: "A pipeline is structured in sequential stages containing one or multiple concurrent jobs. A Job will be executed by a worker. The binary worker is available from CDS Job"
26+
button: "worker reference"
27+
button_path: "/docs/components/worker"
2828
- name: Engine
2929
title: "Engine"
3030
description: "Engine is the core component of CDS"

docs/content/docs/components/cdn/_index.md renamed to docs/content/docs/components/cdn.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,10 @@ You must have at least one storage unit, one file buffer and one log buffer to b
3030

3131
## Use case
3232

33-
Workers and hatcheries communicate with CDN, sending step logs and service log
34-
![CDN_RECEIVE](/images/cdn_receive.png)
33+
Workers and hatcheries communicate with CDN, sending step logs and service log.
3534

36-
CDS UI and CLI communicate with CDN to get entire logs, or stream them
37-
![CDN_GET](/images/cdn_get.png)
35+
![CDN_RECEIVE](/images/cdn_logs_receive.png?width=600px)
36+
37+
CDS UI and CLI communicate with CDN to get entire logs, or stream them.
38+
39+
![CDN_GET](/images/cdn_logs_get.png?width=600px)

docs/content/docs/concepts/files/action-syntax.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,5 +120,5 @@ cdsctl worker model import ./cds-docker-package.yml
120120
Or with a remote file:
121121

122122
```bash
123-
cdsctl action import https://raw.githubusercontent.com/ovh/cds/master/contrib/actions/cds-docker-package.yml
123+
cdsctl action import https://raw.githubusercontent.com/ovh/cds/{{< param "version" "master" >}}/contrib/actions/cds-docker-package.yml
124124
```

docs/content/docs/concepts/files/worker_model-syntax.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ cdsctl worker model import ./go-official-1.13.yml
2525
or with a remote file:
2626

2727
```bash
28-
cdsctl worker model import https://raw.githubusercontent.com/ovh/cds/master/contrib/worker-models/go-official-1.13.yml
28+
cdsctl worker model import https://raw.githubusercontent.com/ovh/cds/{{< param "version" "master" >}}/contrib/worker-models/go-official-1.13.yml
2929
```
3030

3131
{{< note >}}

0 commit comments

Comments
 (0)