pixelfed/.circleci/config.yml

55 lines
1.6 KiB
YAML
Raw Normal View History

2018-08-28 03:33:39 +00:00
# PHP CircleCI 2.0 configuration file
#
# Check https://circleci.com/docs/2.0/language-php/ for more details
#
version: 2
jobs:
build:
docker:
2018-08-28 03:40:30 +00:00
# Specify the version you desire here
2019-05-09 19:15:22 +00:00
- image: circleci/php:7.3-cli-stretch-node
2018-08-28 03:40:30 +00:00
2018-08-28 03:33:39 +00:00
# Specify service dependencies here if necessary
# CircleCI maintains a library of pre-built images
# documented at https://circleci.com/docs/2.0/circleci-images/
2018-08-28 03:40:30 +00:00
# Using the RAM variation mitigates I/O contention
# for database intensive operations.
# - image: circleci/mysql:5.7-ram
2019-05-09 19:15:22 +00:00
#
2018-08-28 03:40:30 +00:00
# - image: redis:2.8.19
2018-08-28 03:33:39 +00:00
steps:
- checkout
2018-08-28 03:40:30 +00:00
- run: sudo apt update && sudo apt install zlib1g-dev libsqlite3-dev
2018-11-29 03:06:19 +00:00
- run: sudo -E docker-php-ext-install bcmath pcntl zip
2018-08-28 03:40:30 +00:00
2018-08-28 03:33:39 +00:00
# Download and cache dependencies
2018-08-28 03:40:30 +00:00
# composer cache
2018-08-28 03:33:39 +00:00
- restore_cache:
keys:
2018-08-28 03:40:30 +00:00
# "composer.lock" can be used if it is committed to the repo
2018-08-28 03:33:39 +00:00
- v1-dependencies-{{ checksum "composer.json" }}
# fallback to using the latest cache if no exact match is found
- v1-dependencies-
- run: composer install -n --prefer-dist
- save_cache:
2018-08-28 03:40:30 +00:00
key: composer-v1-{{ checksum "composer.lock" }}
paths:
- vendor
2018-08-28 03:59:28 +00:00
- run: cp .env.example .env
- run: php artisan storage:link
- run: php artisan key:generate
- run: php artisan config:clear
2018-08-28 03:55:47 +00:00
2018-08-28 03:40:30 +00:00
# run tests with phpunit or codecept
- run: ./vendor/bin/phpunit
- store_test_results:
path: tests/_output
- store_artifacts:
2019-05-09 19:15:22 +00:00
path: tests/_output