-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #102 from LinkValue/feature/app-images
Support application images
- Loading branch information
Showing
74 changed files
with
2,148 additions
and
949 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,15 +24,13 @@ Note: If it unluckily fails at some point, don't hesitate to re-run this command | |
```shell | ||
# connect to the VM | ||
make ssh | ||
# install the project for development (you'll have to press "Enter" several times to keep default parameters) | ||
# install the project for development (you'll have to press "Enter" several times to configure the project with default parameters) | ||
make install | ||
# serve assets for development environment | ||
npm start | ||
``` | ||
|
||
#### 4. Enjoy | ||
|
||
You should see your application up and running at http://appbuild.dev/app_dev.php/ | ||
You should see your application up and running at http://local.appbuild.com/app_dev.php/ | ||
|
||
Try to login using one of the following credentials: | ||
``` | ||
|
@@ -46,13 +44,13 @@ [email protected] => user | |
|
||
Front assets (css/js/images) are handled by [Webpack](https://webpack.js.org/). | ||
|
||
When you're in development environment (i.e. `http://appbuild.dev/app_dev.php/...`), the project is configured to use webpack dev server to serve assets, it means that the project will seems to be broken until you run the following command: | ||
When you're in production environment (i.e. `http://local.appbuild.com/...`), the project will use the assets found in `web/assets`, it means that you'll have to run `make assets-build` each time you edit an asset file to see the modification in your browser (after refreshing it manually). | ||
|
||
When you're in development environment (i.e. `http://local.appbuild.com/app_dev.php/...`), you can also watch asset modifications to benefit from the hot reloading feature of webpack-dev-server, by typing the following command: | ||
```shell | ||
npm start | ||
make assets-watch | ||
``` | ||
|
||
When you're in production environment (i.e. `http://appbuild.dev/...`), the project will use the assets found in `web/assets`, it means that you'll have to run `npm run build` each time you edit an asset file to see the modification in your browser (after refreshing it). | ||
|
||
### Common tasks | ||
```shell | ||
# rebuild the whole database with clean fixtures | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
<?php | ||
|
||
namespace Application\Migrations; | ||
|
||
use Doctrine\DBAL\Migrations\AbstractMigration; | ||
use Doctrine\DBAL\Schema\Schema; | ||
|
||
/** | ||
* Auto-generated Migration: Please modify to your needs! | ||
*/ | ||
class Version20171019161456 extends AbstractMigration | ||
{ | ||
/** | ||
* @param Schema $schema | ||
*/ | ||
public function up(Schema $schema) | ||
{ | ||
// this up() migration is auto-generated, please modify it to your needs | ||
$this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \'mysql\'.'); | ||
|
||
$this->addSql('ALTER TABLE appbuild_application ADD display_image_file_path VARCHAR(510) DEFAULT NULL, ADD full_size_image_file_path VARCHAR(510) DEFAULT NULL'); | ||
$this->addSql('ALTER TABLE appbuild_build CHANGE file_path file_path VARCHAR(510) DEFAULT NULL'); | ||
} | ||
|
||
/** | ||
* @param Schema $schema | ||
*/ | ||
public function down(Schema $schema) | ||
{ | ||
// this down() migration is auto-generated, please modify it to your needs | ||
$this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \'mysql\'.'); | ||
|
||
$this->addSql('ALTER TABLE appbuild_application DROP display_image_file_path, DROP full_size_image_file_path'); | ||
$this->addSql('ALTER TABLE appbuild_build CHANGE file_path file_path VARCHAR(255) DEFAULT NULL COLLATE utf8_unicode_ci'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.