eliasfernandez Posted May 8, 2015 Share Posted May 8, 2015 I'm writing a bash script to install prestashop and apache configuration via command line . php install-dev/index_cli.php --domain=$domain --db_server=localhost --db_name=$project \ --db_user=$user --db_password=$pass --email=$email --password=... --name=$project as said in the docs: http://doc.prestashop.com/display/PS15/Installing+PrestaShop+using+the+command+line It works fine, except for the modules and fixtures, that are not loaded. I think this is the best default behavior but: Is there a way to automate fixtures and modules configuration ? Many Thanks in advance¡ Link to comment Share on other sites More sharing options...
tuk66 Posted May 12, 2015 Share Posted May 12, 2015 Not yet, but I'm working on it. Stay tuned. Link to comment Share on other sites More sharing options...
eliasfernandez Posted May 13, 2015 Author Share Posted May 13, 2015 I'll stay tuned. I really think it would be a great improvement. If i can help you anyway just tell me. Thanx Link to comment Share on other sites More sharing options...
tuk66 Posted May 13, 2015 Share Posted May 13, 2015 Sure. Tell something about your environment, workflow and needs. I'm thinking about deploying PrestaShop into local or remote server, Docker including. Windows, OSX, Linux on any side. PrestaShop will be loaded with huge amount of test records and ready to test a module or the shop as a whole. Unit, integration, functional and acceptance tests with one united interface. Link to comment Share on other sites More sharing options...
eliasfernandez Posted May 13, 2015 Author Share Posted May 13, 2015 I'm currently writing a simple bash to install new prestashop project on a centos 6 dedicated server. The main idea behind is to automate the creation of new sites in an easy proccess. This way, the developer, simply type the project name and sql connection credentials and the script install all the neccesary scripts including host configuration: #!/bin/sh read -p "Nombre del proyecto (será el mismo que la carpeta y el nombre de la bbdd): " project read -p "Dominio (es recomedable un subdominio tipo xxx.desarrollotrevenque.com): " domain read -p "Usuario de la bbdd: " user read -p "Contraseña de la bbdd: " pass read -p "email del proyecto: " email echo "Iniciando proyecto $project ..." # creamos la carpeta de nuestro proyecto mkdir /web_path/$project cp -Rf web_template/* /web_path/$project cp web_template/.gitignore /web_path/$project cd /web_path/$project sudo chown -Rf code:apache web log sudo chmod -Rf 775 web log echo "<VirtualHost *:80> ... $project configuration--- </VirtualHost>" >> vhost/dev.vhost sudo ln -s /web_path/$project/vhost/dev.vhost "/etc/httpd/sites-available/$project.vhost.conf" # Instalamos Prestashop wget https://github.com/PrestaShop/PrestaShop/archive/1.6.zip unzip 1.6.zip mv PrestaShop-1.6 /web_path/$project/web mysql -u$user -p$pass -e " CREATE DATABASE $project" php /web_path/$project/web/install-dev/index_cli.php --domain=$domain --db_server=localhost --db_name=$project --db_user=$user --db_password=$pass --email=$email --password=password --first-name=test--second-name=test--name=$project --language=es It works like a charm. But the default prestashop installed doesn't have: Modules Any sample data Ideally, for me, the script must include two options: Modules option:--modules=module1,module2, or maybe something lik --default-modules=true Data:--fixtures=/path/ Hope it helps Link to comment Share on other sites More sharing options...
tuk66 Posted May 13, 2015 Share Posted May 13, 2015 I see. At first glance, it looks simple. Unfortunately, there are so many things to think about. I'm working on it for several months now and it is really tough job. We will see in the future. Link to comment Share on other sites More sharing options...
eliasfernandez Posted May 13, 2015 Author Share Posted May 13, 2015 Of course. I know this simplicity always have a huge amount of programming hours from smart people. Thanks for your tought job ¡ I'll try other way. Link to comment Share on other sites More sharing options...
yguerin Posted August 11, 2016 Share Posted August 11, 2016 Sure. Tell something about your environment, workflow and needs. I'm thinking about deploying PrestaShop into local or remote server, Docker including. Windows, OSX, Linux on any side. PrestaShop will be loaded with huge amount of test records and ready to test a module or the shop as a whole. Unit, integration, functional and acceptance tests with one united interface. Dear, Actually on our environment we use vagrant (jenkins, svn, virtualbox) - virtualbox: ubuntu 14.04 server - vagrant: install everything from the last commit (jenkins/svn) I am looking for a way to automate the process of installing the modules/themes via scripting vagrant engine ? Any news ? Regards Yves Link to comment Share on other sites More sharing options...
arnaud.sylvestre Posted June 22, 2017 Share Posted June 22, 2017 (edited) HI, If you wish to install a module through command line, you can do it with : php app\console prestashop:module install <module_name> where <module_name> is the name of your module execute this command inside the prestashop main folder. Hope it helps ! Edited June 22, 2017 by arnaud.sylvestre (see edit history) 1 Link to comment Share on other sites More sharing options...
prestol Posted April 3, 2020 Share Posted April 3, 2020 you can just install a module from the command line https://devdocs.prestashop.com/1.7/modules/concepts/commands/ and then import the database tables from a working configuration. Link to comment Share on other sites More sharing options...
Alexia851 Posted July 14, 2022 Share Posted July 14, 2022 On 6/22/2017 at 1:06 PM, arnaud.sylvestre said: HI, If you wish to install a module through command line, you can do it with : php app\console prestashop:module install <module_name> where <module_name> is the name of your module execute this command inside the prestashop main folder. Hope it helps ! HI, It won execute and it just throws: Could not open input file: appconsole Any newer solutions? Thx. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now