2020-12-27 07:17:44 +01:00
|
|
|
version: v1.0
|
2021-01-22 11:38:44 +01:00
|
|
|
name: Docker Build
|
2020-12-27 07:17:44 +01:00
|
|
|
agent:
|
|
|
|
machine:
|
|
|
|
type: e1-standard-2
|
|
|
|
os_image: ubuntu1804
|
|
|
|
blocks:
|
2020-12-27 07:57:55 +01:00
|
|
|
- name: Build
|
2020-12-27 07:17:44 +01:00
|
|
|
task:
|
|
|
|
jobs:
|
2020-12-27 07:57:55 +01:00
|
|
|
- name: 'Alpine'
|
2020-12-27 07:17:44 +01:00
|
|
|
commands:
|
|
|
|
- checkout
|
2020-12-27 07:25:00 +01:00
|
|
|
- cd alpine
|
2021-01-29 04:42:18 +01:00
|
|
|
- docker build --network=host -t docker.pkg.github.com/catdeployed/docker-postal/postal:alpine .
|
|
|
|
- docker save -o postal-alpine-container.tar docker.pkg.github.com/catdeployed/docker-postal/postal:alpine
|
2020-12-27 08:28:26 +01:00
|
|
|
- artifact push workflow postal-alpine-container.tar --expire-in 1d
|
2020-12-27 07:57:55 +01:00
|
|
|
- name: 'Ubuntu'
|
2020-12-27 07:25:00 +01:00
|
|
|
commands:
|
|
|
|
- checkout
|
2020-12-27 07:30:34 +01:00
|
|
|
- cd ubuntu
|
2021-01-29 04:42:18 +01:00
|
|
|
- docker build --network=host -t docker.pkg.github.com/catdeployed/docker-postal/postal:ubuntu .
|
|
|
|
- docker save -o postal-ubuntu-container.tar docker.pkg.github.com/catdeployed/docker-postal/postal:ubuntu
|
2020-12-27 08:28:26 +01:00
|
|
|
- artifact push workflow postal-ubuntu-container.tar --expire-in 1d
|
2020-12-27 07:25:00 +01:00
|
|
|
promotions:
|
2021-03-18 06:23:03 +01:00
|
|
|
- name: Docker Image Testing
|
2020-12-27 07:30:34 +01:00
|
|
|
pipeline_file: tests.yml
|
2020-12-27 07:35:35 +01:00
|
|
|
auto_promote:
|
|
|
|
when: result = 'passed'
|