From 5a06d55f1baf7b3ca01550e22f0435a859b86554 Mon Sep 17 00:00:00 2001 From: Jazio Date: Thu, 8 Mar 2018 17:17:13 +0100 Subject: [PATCH 1/5] mohamed --- .gitignore | 1 + composer.json | 2 +- composer.lock | 76 +++++++++++++++++++++++++++++++++++++++++++++ docker-compose.yaml | 24 ++++++++++++++ drone.yaml | 11 +++++++ index.php | 4 +-- 6 files changed, 115 insertions(+), 3 deletions(-) create mode 100644 .gitignore create mode 100644 composer.lock create mode 100644 docker-compose.yaml create mode 100644 drone.yaml diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a725465 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +vendor/ \ No newline at end of file diff --git a/composer.json b/composer.json index e7ac977..00e7dd8 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,5 @@ { "require": { - "symfony/yaml" : "*", + "symfony/yaml" : "*" } } diff --git a/composer.lock b/composer.lock new file mode 100644 index 0000000..9d2aac1 --- /dev/null +++ b/composer.lock @@ -0,0 +1,76 @@ +{ + "_readme": [ + "This file locks the dependencies of your project to a known state", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", + "This file is @generated automatically" + ], + "content-hash": "1d14b066a73960476c178ecf92bed18f", + "packages": [ + { + "name": "symfony/yaml", + "version": "v3.4.6", + "source": { + "type": "git", + "url": "https://github.com/symfony/yaml.git", + "reference": "6af42631dcf89e9c616242c900d6c52bd53bd1bb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/yaml/zipball/6af42631dcf89e9c616242c900d6c52bd53bd1bb", + "reference": "6af42631dcf89e9c616242c900d6c52bd53bd1bb", + "shasum": "" + }, + "require": { + "php": "^5.5.9|>=7.0.8" + }, + "conflict": { + "symfony/console": "<3.4" + }, + "require-dev": { + "symfony/console": "~3.4|~4.0" + }, + "suggest": { + "symfony/console": "For validating YAML files using the lint command" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Yaml\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Yaml Component", + "homepage": "https://symfony.com", + "time": "2018-02-16T09:50:28+00:00" + } + ], + "packages-dev": [], + "aliases": [], + "minimum-stability": "stable", + "stability-flags": [], + "prefer-stable": false, + "prefer-lowest": false, + "platform": [], + "platform-dev": [] +} diff --git a/docker-compose.yaml b/docker-compose.yaml new file mode 100644 index 0000000..c251cc5 --- /dev/null +++ b/docker-compose.yaml @@ -0,0 +1,24 @@ +version: '2' +services: + + # Define a PHP webserver + php-webserver: + # Use a PHP image with apache + image: fpfis/php56-dev + # We need to force execution in this folder + working_dir: /app/build/ + command: composer install + # Define settings + environment: + - XDEBUG=true + - DOCUMENT_ROOT=/app/build + # Mount a local volume in the container + volumes: + - ./:/app/build + # Share the container port with the host + ports: + - 80:8080 + + # Define a mysql service + mysql: + image: fpfis/mysql56 \ No newline at end of file diff --git a/drone.yaml b/drone.yaml new file mode 100644 index 0000000..65013e2 --- /dev/null +++ b/drone.yaml @@ -0,0 +1,11 @@ +services: + web: + image: fpfis/php56-dev + environment: + - DOCUMENT_ROOT=/app/build/ + +pipeline: + build: + image: fpfis/php56-dev + commands: + - composer install \ No newline at end of file diff --git a/index.php b/index.php index 03efc33..83a40d1 100644 --- a/index.php +++ b/index.php @@ -7,7 +7,7 @@ $array = array( 'foo' => 'bar', - 'bar' => array('foo' => 'bar', 'bar' => 'baz' => 'test'), + 'bar' => array('foo' => 'bar', 'baz' => 'test'), ); -echo Yaml::dump($array); +echo Yaml::dump($array, 2, 8); From 5f57f20a5b6ee9fcfeef1e6b465c0b4bb93da604 Mon Sep 17 00:00:00 2001 From: Jazio Date: Thu, 8 Mar 2018 17:17:13 +0100 Subject: [PATCH 2/5] mohamed --- .gitignore | 1 + composer.json | 2 +- composer.lock | 76 +++++++++++++++++++++++++++++++++++++++++++++ docker-compose.yaml | 24 ++++++++++++++ drone.yaml | 11 +++++++ index.php | 4 +-- 6 files changed, 115 insertions(+), 3 deletions(-) create mode 100644 .gitignore create mode 100644 composer.lock create mode 100644 docker-compose.yaml create mode 100644 drone.yaml diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a725465 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +vendor/ \ No newline at end of file diff --git a/composer.json b/composer.json index e7ac977..00e7dd8 100644 --- a/composer.json +++ b/composer.json @@ -1,5 +1,5 @@ { "require": { - "symfony/yaml" : "*", + "symfony/yaml" : "*" } } diff --git a/composer.lock b/composer.lock new file mode 100644 index 0000000..9d2aac1 --- /dev/null +++ b/composer.lock @@ -0,0 +1,76 @@ +{ + "_readme": [ + "This file locks the dependencies of your project to a known state", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", + "This file is @generated automatically" + ], + "content-hash": "1d14b066a73960476c178ecf92bed18f", + "packages": [ + { + "name": "symfony/yaml", + "version": "v3.4.6", + "source": { + "type": "git", + "url": "https://github.com/symfony/yaml.git", + "reference": "6af42631dcf89e9c616242c900d6c52bd53bd1bb" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/yaml/zipball/6af42631dcf89e9c616242c900d6c52bd53bd1bb", + "reference": "6af42631dcf89e9c616242c900d6c52bd53bd1bb", + "shasum": "" + }, + "require": { + "php": "^5.5.9|>=7.0.8" + }, + "conflict": { + "symfony/console": "<3.4" + }, + "require-dev": { + "symfony/console": "~3.4|~4.0" + }, + "suggest": { + "symfony/console": "For validating YAML files using the lint command" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Component\\Yaml\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony Yaml Component", + "homepage": "https://symfony.com", + "time": "2018-02-16T09:50:28+00:00" + } + ], + "packages-dev": [], + "aliases": [], + "minimum-stability": "stable", + "stability-flags": [], + "prefer-stable": false, + "prefer-lowest": false, + "platform": [], + "platform-dev": [] +} diff --git a/docker-compose.yaml b/docker-compose.yaml new file mode 100644 index 0000000..c251cc5 --- /dev/null +++ b/docker-compose.yaml @@ -0,0 +1,24 @@ +version: '2' +services: + + # Define a PHP webserver + php-webserver: + # Use a PHP image with apache + image: fpfis/php56-dev + # We need to force execution in this folder + working_dir: /app/build/ + command: composer install + # Define settings + environment: + - XDEBUG=true + - DOCUMENT_ROOT=/app/build + # Mount a local volume in the container + volumes: + - ./:/app/build + # Share the container port with the host + ports: + - 80:8080 + + # Define a mysql service + mysql: + image: fpfis/mysql56 \ No newline at end of file diff --git a/drone.yaml b/drone.yaml new file mode 100644 index 0000000..65013e2 --- /dev/null +++ b/drone.yaml @@ -0,0 +1,11 @@ +services: + web: + image: fpfis/php56-dev + environment: + - DOCUMENT_ROOT=/app/build/ + +pipeline: + build: + image: fpfis/php56-dev + commands: + - composer install \ No newline at end of file diff --git a/index.php b/index.php index 03efc33..83a40d1 100644 --- a/index.php +++ b/index.php @@ -7,7 +7,7 @@ $array = array( 'foo' => 'bar', - 'bar' => array('foo' => 'bar', 'bar' => 'baz' => 'test'), + 'bar' => array('foo' => 'bar', 'baz' => 'test'), ); -echo Yaml::dump($array); +echo Yaml::dump($array, 2, 8); From 148a676e47a97174fe31dd01785bfe2eac8104be Mon Sep 17 00:00:00 2001 From: Jazio Date: Thu, 8 Mar 2018 17:25:53 +0100 Subject: [PATCH 3/5] fix drone.yaml --- drone.yaml | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/drone.yaml b/drone.yaml index 65013e2..f12ba81 100644 --- a/drone.yaml +++ b/drone.yaml @@ -1,11 +1,20 @@ -services: - web: +# Declare a pipeline +pipeline: + # Declare pipeline step + composer-install: + # Use image for step image: fpfis/php56-dev - environment: - - DOCUMENT_ROOT=/app/build/ + # Run commands from this image + commands: + - composer install --ansi -pipeline: - build: + # Declare another step + lint-code: image: fpfis/php56-dev commands: - - composer install \ No newline at end of file + - php -l index.php + + run-code: + image: fpfis/php56 + commands: + - php index.php \ No newline at end of file From d75eff5e643592cad72f416b5053d56cb3bcef65 Mon Sep 17 00:00:00 2001 From: Jazio Date: Thu, 8 Mar 2018 17:32:15 +0100 Subject: [PATCH 4/5] another fix --- drone.yaml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drone.yaml b/drone.yaml index bf665dd..903fb4b 100644 --- a/drone.yaml +++ b/drone.yaml @@ -1,19 +1,20 @@ +# Declare a pipeline pipeline: # Declare pipeline step composer-install: # Use image for step - image: fpfis/php56-dev + image: fpfis/php71-build # Run commands from this image commands: - composer install --ansi # Declare another step lint-code: - image: fpfis/php56-dev + image: fpfis/php71-build commands: - php -l index.php run-code: - image: fpfis/php56 + image: fpfis/php71-build commands: - - php index.php + - php index.php From 46914c23124d2bee7c4d7297e7a78493938a0000 Mon Sep 17 00:00:00 2001 From: Jazio Date: Thu, 8 Mar 2018 17:34:45 +0100 Subject: [PATCH 5/5] file name change --- drone.yaml => .drone.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename drone.yaml => .drone.yml (100%) diff --git a/drone.yaml b/.drone.yml similarity index 100% rename from drone.yaml rename to .drone.yml