Skip to content

Fix demo installation#31

Merged
dunglas merged 1 commit into
api-platform:masterfrom
aaa2000:fix-demo-installation
Sep 17, 2018
Merged

Fix demo installation#31
dunglas merged 1 commit into
api-platform:masterfrom
aaa2000:fix-demo-installation

Conversation

@aaa2000

@aaa2000 aaa2000 commented Sep 17, 2018

Copy link
Copy Markdown
Contributor
Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #30
License MIT

Comment thread api/composer.json
"cache:clear": "symfony-cmd",
"assets:install --symlink --relative %PUBLIC_DIR%": "symfony-cmd",
"assets:install %PUBLIC_DIR%": "symfony-cmd",
"security-checker security:check": "script"

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I noticed that the Pull Request #24 has removed the command bin/console assets:install https://github.com/api-platform/demo/pull/24/files#diff-507acfb69e262d39c47cc1a687c1aab4L12 and symbolic links prevent assets loading.

The flex recipe remove now "--relative" and "--symlink" options by default See symfony/recipes#406

@dunglas dunglas merged commit 3a91ee1 into api-platform:master Sep 17, 2018
@dunglas

dunglas commented Sep 17, 2018

Copy link
Copy Markdown
Member

Thanks for fixing the demo @aaa2000!

@aaa2000

aaa2000 commented Sep 17, 2018

Copy link
Copy Markdown
Contributor Author

Wow you are fast, I have a doubt about until bin/console doctrine:query:sql "SELECT 1" --quiet; do, now I try with until pg_isready --timeout=0 --dbname="${DATABASE_URL}"; do and it works. (I have removed containers and api-platform-demo_db-data volume before retry)

The command can pollute the output

php_1          |  [OK]
php_1          | Waiting for Postgres to be ready...
php_1          | 2018-09-17T20:51:41+00:00 [error] Error thrown while running command "doctrine:query:sql 'SELECT 1' --quiet". Message: "An exception occurred in driver: SQLSTATE[08006] [7] FATAL:  the database system is starting up"
php_1          | 
php_1          | In AbstractPostgreSQLDriver.php line 93:
php_1          |                                                                                
php_1          |   An exception occurred in driver: SQLSTATE[08006] [7] FATAL:  the database s  
php_1          |   ystem is starting up                                                         
php_1          |                                                                                
php_1          | 
php_1          | In PDOConnection.php line 50:
php_1          |                                                                   
php_1          |   SQLSTATE[08006] [7] FATAL:  the database system is starting up  
php_1          |                                                                   
php_1          | 
php_1          | In PDOConnection.php line 46:
php_1          |                                                                   
php_1          |   SQLSTATE[08006] [7] FATAL:  the database system is starting up  
php_1          |                                                                   
php_1          | 
php_1          | doctrine:query:sql [--depth DEPTH] [--force-fetch] [--connection [CONNECTION]] [-h|--help] [-q|--quiet] [-v|vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction] [-e|--env ENV] [--no-debug] [--] <command> <sql>
php_1          | 
php_1          | 
php_1          |  Updating database schema...
php_1          | 
php_1          |      8 queries were executed
php_1          | 
php_1          |  [OK] Database schema updated successfully!                                     
php_1          | 

aaa2000 added a commit to aaa2000/demo that referenced this pull request Sep 19, 2018
aaa2000 added a commit to aaa2000/demo that referenced this pull request Sep 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants