jcavat / docker-lamp Goto Github PK
View Code? Open in Web Editor NEWDocker with Apache, MySql, PhpMyAdmin and Php
License: The Unlicense
Docker with Apache, MySql, PhpMyAdmin and Php
License: The Unlicense
I'm try to deploy a web app to docker and i write an .htaccess like the code below :
**RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^(.+)$ index.php?url=$1 [QSA,L]**
And it cause an internal server error , but when i remove the code it works normally. Can you explain where it is wrong , because i have not experince in writing htaccess file .
You should set mysql version to 5.7 in order to make it work without any hazzle.
what is the database password for root
Hi, how to enable php extension gd and zip, Thank you.
I Know that with docker-compose up... I spin up Everything.
But what About the DB? I Know I Can't manually import it... But is there any automatic mechanism that will import the dump?
Travelling to localhost:8001 shows this:
Hi! I'm happy
Warning: mysqli_connect(): (HY000/1049): Unknown database 'myDb' in /var/www/html/index.php on line 19
Warning: mysqli_query() expects parameter 1 to be mysqli, boolean given in /var/www/html/index.php on line 23
Fatal error: Uncaught Error: Call to a member function fetch_array() on null in /var/www/html/index.php:27 Stack trace: #0 {main} thrown in /var/www/html/index.php on line 27
How could I install PDO Driver?
I try to change myDB.sql to another *.sql file but when i open phpmyadmin it still show myDb database not my custom database . How can i solve it ?
how enable modrevrite
Hi,
I am trying to have a ready docker for LAMP. This is so far a gaziliion try but looks much more close to a functional one. Still I am getting this:
ERROR: for db Cannot start service db: driver failed programming external connectivity on endpoint dockerlamp_db_1 (ab07b9901a6273dd0ab46f68f17f1ad6643443ef9a35e7699c1c6d18cbf21235): Error starting userland proxy: listen tcp 0.0.0.0:3306: bind: address already in use
ERROR: Encountered errors while bringing up the project.
Hello sir, could you please make the same lightweight dockerfile and .yml with all the same component, with only change that nginx be included against httpd?
Thanks.
Following is mysql part of docker-compose.yml file :
db:
image: mysql:8.0
ports:
- "3306:3306"
command: --default-authentication-plugin=mysql_native_password
environment:
MYSQL_DATABASE: myDb
MYSQL_USER: root
MYSQL_PASSWORD: ''
MYSQL_ROOT_PASSWORD: ''
MYSQL_ALLOW_EMPTY_PASSWORD : 'yes'
restart: always
volumes:
- ./dump:/docker-entrypoint-initdb.d
- ./conf:/etc/mysql/conf.d
- persistent:/var/lib/mysql
networks:
- default
Now, I don't know for what weird reason, but the mysql has added "docker" as user which doesn't have access to create / drop databases. I suspect, this is because of my earlier trial setup which had user named 'docker' in it and the same is getting carried forwarded for mysql. The command 'docker-compose up -d' seems not resetting the mysql image and user "root" is not getting created.
Is there any ways I could add this user "root" ? Since don't have root access so can't even know if there is any root user added already. I tried "docker-compose exec db mysql -u root -p" with "root" as password, says access denied... with blank password, says access denied...
Any help please ?
Thanks
connection issue between db container and app container
Hi,
First of all, wanna say, this docker system is great!
Running into a bit of an issue though. Whenever I try to insert data into a database, it just doesn't work... I've got a completely fresh download from the repo, but it won't insert that data.
Do you have any idea on what I could do?
Hi, I am getting an error:
Warning: mysqli_connect(): (HY000/1130): Host 'dockerapp_www_1.dockerapp_default' is not allowed to connect to this MySQL server in /var/www/html/index.php on line 19
Warning: mysqli_query() expects parameter 1 to be mysqli, bool given in /var/www/html/index.php on line 23
Fatal error: Uncaught Error: Call to a member function fetch_array() on null in /var/www/html/index.php:27 Stack trace: #0 {main} thrown in /var/www/html/index.php on line 27
There is a typo in the Readme file regarding image name at docker-compose exec bd
gd and pdo_mysql not not able to install. please guide me to get a solution , thank s in advance
How can I change the PHP version?
For example, I want to update the current image's PHP to 7.2, how would I do that?
My org needs Security Certificate to be installed. So placed commands to copy the certificate file in Dockerfile which works great !
However, for installing the same, In Dockerfile I added the line
RUN dpkg-reconfigure ca-certificates
But it doesn't add the Certificate. I even tried with
RUN update-ca-certificates
but it still doesn't add the Certificate.
I confirmed this by going into the docker shell and trying and executing
curl -v https://www.google.com
which failed miserably.
Any specific changes I need to do in my Dockerfile to install the Certificate please ?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.