added image to article
continuous-integration/drone/push Build is failing
Details
continuous-integration/drone/push Build is failing
Details
This commit is contained in:
parent
9910adebb8
commit
f4db70453f
|
|
@ -12,9 +12,9 @@ steps:
|
|||
- name: docker
|
||||
image: plugins/docker
|
||||
settings:
|
||||
repo: registry.while-false.de/blog
|
||||
username: stephan
|
||||
password: eRFJ1R7UNo5zv1FFvLzv
|
||||
repo: registry.while-false.de/blog
|
||||
tags:
|
||||
- 'latest'
|
||||
- '1.3.0'
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 56 KiB |
|
|
@ -70,6 +70,7 @@ steps:
|
|||
- name: build
|
||||
image: node:alpine
|
||||
commands:
|
||||
- npm install
|
||||
- npx gatsby build
|
||||
|
||||
- name: docker
|
||||
|
|
@ -83,15 +84,17 @@ steps:
|
|||
- '1.3.0'
|
||||
```
|
||||
|
||||
For now I only require two steps:
|
||||
For now I only require three steps:
|
||||
|
||||
1. build the gatsby project
|
||||
2. build the new docker image and push it to the registry
|
||||
1. install node.js dependencies
|
||||
2. build the gatsby project
|
||||
3. build the new docker image and push it to the registry
|
||||
|
||||
An additional benefit of the drone build is this beatiful badge, every project has nowadays, conveniently prepared as markdown:
|
||||
|
||||
[](https://drone.while-false.de/stephan/blog)
|
||||
```markdown
|
||||
[](https://drone.while-false.de/stephan/blog)
|
||||
```
|
||||
|
||||
Also, It has nice visualization of the build process with logs for debugging in case it's needed:
|
||||

|
||||
|
||||
Then, the last required step is to update the running container to the new version. The event on which to react would be the upload to the registry. There are some ways to handle this myself using webhooks, but as with the build trigger I decided to take a route a little more convenient: use [Watchtower](https://containrrr.github.io/watchtower). I tried watchtower before and don't feel comfortable blindly updating every container I run, so I [configure it to just watch the one blog container and update that automatically](https://containrrr.github.io/watchtower/container-selection/). As I am the only one pushing updates of the image for the blog I can take precautions when I know something will break.
|
||||
|
|
|
|||
Loading…
Reference in New Issue