Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
L
laravel-mongodb
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
sinan
laravel-mongodb
Commits
27ad5f35
Unverified
Commit
27ad5f35
authored
Feb 16, 2018
by
Thilanga Pitigala
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added docker support to travis
parent
7347a87b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
34 additions
and
30 deletions
+34
-30
.travis.yml
.travis.yml
+27
-29
docker-compose.yml
docker-compose.yml
+3
-0
Dockerfile
docker/Dockerfile
+4
-0
entrypoint.sh
docker/entrypoint.sh
+0
-1
No files found.
.travis.yml
View file @
27ad5f35
sudo
:
required
dist
:
trusty
language
:
php
php
:
-
7
-
7.1
matrix
:
fast_finish
:
true
sudo
:
false
-
"
7.1"
-
"
7.0"
services
:
-
mongodb
-
mysql
addons
:
apt
:
sources
:
-
mongodb-3.0-precise
packages
:
-
mongodb-org-server
before_script
:
-
pecl install mongodb
-
mysql -e 'create database unittest;'
-
travis_retry composer self-update
-
travis_retry composer install --no-interaction
script
:
-
docker
install
:
# Update docker-engine using Ubuntu 'trusty' apt repo
-
>
curl -sSL "https://get.docker.com/gpg" |
sudo -E apt-key add -
-
>
echo "deb https://apt.dockerproject.org/repo ubuntu-trusty main" |
sudo tee -a /etc/apt/sources.list
-
sudo apt-get update
-
>
sudo apt-get -o Dpkg::Options::="--force-confdef" \
-o Dpkg::Options::="--force-confold" --assume-yes install docker-engine --allow-unauthenticated
-
docker version
-
mkdir -p build/logs
-
vendor/bin/phpunit --coverage-clover build/logs/clover.xml
# Update docker-compose via pip
-
sudo pip install docker-compose
-
docker-compose version
-
docker-compose up --build -d
-
docker ps -a
-
docker exec -it php_test composer install --prefer-source --no-interaction
after_success
:
-
sh -c 'php vendor/bin/coveralls -v'
script
:
-
docker exec -it php_test php ./vendor/bin/phpunit --coverage-clover build/logs/clover.xml
docker-compose.yml
View file @
27ad5f35
...
...
@@ -3,6 +3,7 @@ version: '3'
services
:
php
:
container_name
:
php_test
build
:
context
:
.
dockerfile
:
docker/Dockerfile
...
...
@@ -15,6 +16,7 @@ services:
-
mongodb
mysql
:
container_name
:
mysql_test
image
:
mysql
environment
:
MYSQL_ROOT_PASSWORD
:
...
...
@@ -24,6 +26,7 @@ services:
driver
:
none
mongodb
:
container_name
:
mongodb_test
image
:
mongo
logging
:
driver
:
none
docker/Dockerfile
View file @
27ad5f35
...
...
@@ -4,3 +4,7 @@ RUN apt-get update && \
apt-get
install
-y
autoconf pkg-config libssl-dev
&&
\
pecl
install
mongodb
&&
docker-php-ext-enable mongodb
&&
\
docker-php-ext-install
-j
$(
nproc
)
pdo pdo_mysql
RUN
curl
-sS
https://getcomposer.org/installer | php
\
&&
mv
composer.phar /usr/local/bin/
\
&&
ln
-s
/usr/local/bin/composer.phar /usr/local/bin/composer
docker/entrypoint.sh
View file @
27ad5f35
#!/usr/bin/env bash
sleep
3
&&
php ./vendor/bin/phpunit
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment