MyShaarli/.drone.yml
nodiscc 832739e58f
switch continuous integration system to Drone CI:
- add .drone.yml, reimplement tasks from .travis.yml (php/node/python test suites)
- ref. https://github.com/shaarli/Shaarli/issues/1649
- https://www.drone.io/enterprise/opensource/
- https://cloud.drone.io/shaarli/Shaarli/settings
- https://docs.drone.io/pipeline/docker/syntax/steps/
- https://docs.drone.io/pipeline/docker/syntax/cloning/
- https://docs.drone.io/pipeline/environment/reference/
- https://docs.drone.io/pipeline/configuration/
- https://docs.drone.io/pipeline/overview/
- https://docs.drone.io/pipeline/docker/syntax/volumes/
- https://docs.drone.io/pipeline/docker/syntax/volumes/temporary/
- php: use custom php base images with prebuilt PHP extensions and composer (speed up build process) (https://hub.docker.com/r/shaarli/drone-ci-base, https://www.github.com/shaarli/drone-ci-base, https://hub.docker.com/repository/docker/shaarli/drone-ci-base/builds)
- no need to port $PATH update command, the default node:10 image already has the correct $PATH
- don't force pull of latest images to speed up builds
- the default is to use a local/cached image when the image is not tagged :latest
- https://docs.drone.io/pipeline/docker/syntax/parallelism/
- https://docs.drone.io/pipeline/environment/reference/drone-git-http-url/
- ignore PHP version requirements for https://packagist.org/packages/pubsubhubbub/publisher, pending merge of https://github.com/pubsubhubbub/php-publisher/pull/11
- closes https://github.com/shaarli/Shaarli/issues/1649
2021-05-13 14:28:11 +02:00

115 lines
2.3 KiB
YAML

---
kind: pipeline
type: docker
name: php-8.0
steps:
- name: test-php-8.0
image: shaarli/drone-ci-base:8.0
commands:
- composer config --unset platform && composer config platform.php 8.0
- composer update --ignore-platform-req=php
- composer remove --dev --ignore-platform-req=php phpunit/phpunit
- composer require --dev --ignore-platform-req=php phpunit/php-text-template ^2.0
- composer require --dev --ignore-platform-req=php phpunit/phpunit ^9.0
- make clean
- make check_permissions
- make code_sniffer
- make all_tests
---
kind: pipeline
type: docker
name: php-7.4
steps:
- name: test-php-7.4
image: shaarli/drone-ci-base:7.4
commands:
- composer config --unset platform && composer config platform.php 7.4
- composer update
- make clean
- make check_permissions
- make code_sniffer
- make all_tests
---
kind: pipeline
type: docker
name: php-7.3
steps:
- name: test-php-7.3
image: shaarli/drone-ci-base:7.3
commands:
- composer config --unset platform && composer config platform.php 7.3
- composer update
- make clean
- make check_permissions
- make code_sniffer
- make all_tests
---
kind: pipeline
type: docker
name: php-7.2
steps:
- name: test-php-7.2
image: shaarli/drone-ci-base:7.2
commands:
- composer config --unset platform && composer config platform.php 7.2
- composer update
- make clean
- make check_permissions
- make code_sniffer
- make all_tests
---
kind: pipeline
type: docker
name: php-7.1
steps:
- name: test-php-7.1
image: shaarli/drone-ci-base:7.1
commands:
- composer config --unset platform && composer config platform.php 7.1
- composer update
- make clean
- make check_permissions
- make code_sniffer
- make all_tests
---
kind: pipeline
type: docker
name: node-10
steps:
- name: test-node-10
image: node:10
commands:
- yarn install
- yarn run build # verify successful frontend builds
- make eslint # javascript static analysis
- make sasslint # linter for SASS syntax
---
kind: pipeline
type: docker
name: python-3.6
steps:
- name: test-python-3.6
image: python:3.6-slim
commands:
- pip install mkdocs
- mkdocs build --clean