On 3/15/2018 7:41 PM, Percival John Hackworth wrote:
> On 15-Mar-2018, Jerry Stuckle wrote
> (in article<p8edam$33u$
1...@jstuckle.eternal-september.org>):
>
>> On 3/15/2018 4:08 AM, alex wrote:
>>> Il 14/03/2018 22:15, Jerry Stuckle ha scritto:
>>>>
>>>> Is your database host actually named "mysql"?
>>>
>>> Maybe you're right, but how do I know the name?
>>> How can I configure it?
>>
>> Forget docker. MySQL is not that hard to configure. Look at the manual
>> at
dev.mysql.com; it's long but all you need to look at is the
>> installation and configuration section for your OS.
>>
>> Or, better yet - which flavor of Linux are you using? Most have RPMs or
>> similar to install MySQL on the system from their repository.
>>
>> And the host name is the name of your server - i.e. "localhost" if MySQL
>> is on the same server you are running your scripts on, or the host name
>> or ip address of a remote server.
>
> Jerry's recommendations (hell almost anything he posts) should be taken with
> several Kg of NaCl. Usually all I hear when I read his stuff are those
> trombones from the Peanuts cartoons.
>
> Anyway, the Docker container for mysql or mariadb has everything you need to
> run an instance with on-system storage. All you need is an init sql script
> and a mount point to store the files. You can either take it and run it as
> part of your Docker-compose file or take the container's Dockerfile and
> modify it to your own needs.
>
> If this is running on a VM then I'd follow Jerry's advise and just install
> mysql/maria into the base VM (Yes, I'm just a shocked as you are). Populate
> it and just have it as part of the system that that your containers access.
>
OTOH, I've installed MySQL many times and never needed Docker. It just
adds another unnecessary level of complexity. You can install both PHP
and MySQL from the Ubuntu repository and PDO requires nothing more. No
init script required and the mount point is already defined.
But then we already know you have limited technical capabilities and
have no idea how to manually install and configure anything. There is
zero difference between running in a VM and running standalone as far as
the applications are concerned. You can get a full server, or a virtual
server. In the latter case you're running under a VM. But as far as
the applications, everything is identical. Just some minor differences
deep in the kernel.