I am trying to stand up a project in Docker. Although I did everything right, when I try to enter localhost, the site does not open when I try to enter localhost, it gives a warning saying localhost is not responding.
This is the log records returned in docker.
2023-06-29 21:19:24 logistdepo-db-1 | '/var/lib/mysql/mysql.sock' -> '/var/run/mysqld/mysqld.sock'
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.453685Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.461437Z 0 [Note] mysqld (mysqld 5.7.42) starting as process 1 ...
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.494802Z 0 [Note] InnoDB: PUNCH HOLE support available
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.496260Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.496326Z 0 [Note] InnoDB: Uses event mutexes
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.496398Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.496505Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.13
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.496596Z 0 [Note] InnoDB: Using Linux native AIO
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.501540Z 0 [Note] InnoDB: Number of pools: 1
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.503154Z 0 [Note] InnoDB: Using CPU crc32 instructions
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.505257Z 0 [ERROR] InnoDB: Linux Native AIO interface is not supported on this platform. Please check your OS documentation and install appropriate binary of InnoDB.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.505421Z 0 [Note] InnoDB: You can disable Linux Native AIO by setting innodb_use_native_aio = 0 in my.cnf
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.505578Z 0 [Warning] InnoDB: Linux Native AIO disabled.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.509171Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.554390Z 0 [Note] InnoDB: Completed initialization of buffer pool
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.587196Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.610711Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.763982Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.765065Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.785693Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.793358Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.793475Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.802483Z 0 [Note] InnoDB: Waiting for purge to start
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.853435Z 0 [Note] InnoDB: 5.7.42 started; log sequence number 12217930
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.857150Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.858566Z 0 [Note] Plugin 'FEDERATED' is disabled.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.899501Z 0 [Note] InnoDB: Buffer pool(s) load completed at 230629 18:19:24
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.910539Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.910602Z 0 [Note] Skipping generation of SSL certificates as certificate files are present in data directory.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.910677Z 0 [Warning] A deprecated TLS version TLSv1 is enabled. Please use TLSv1.2 or higher.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.910696Z 0 [Warning] A deprecated TLS version TLSv1.1 is enabled. Please use TLSv1.2 or higher.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.925708Z 0 [Warning] CA certificate ca.pem is self signed.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.926678Z 0 [Note] Skipping generation of RSA key pair as key files are present in data directory.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.929826Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.930409Z 0 [Note] IPv6 is available.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.930745Z 0 [Note] - '::' resolves to '::';
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.931048Z 0 [Note] Server socket created on IP: '::'.
2023-06-29 21:19:24 logistdepo-db-1 | 2023-06-29T18:19:24.933164Z 0 [Warning] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
2023-06-29 21:19:25 logistdepo-db-1 | 2023-06-29T18:19:25.001724Z 0 [Note] Event Scheduler: Loaded 0 events
2023-06-29 21:19:25 logistdepo-db-1 | 2023-06-29T18:19:25.003272Z 0 [Note] mysqld: ready for connections.
2023-06-29 21:19:25 logistdepo-db-1 | Version: '5.7.42' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server (GPL)
2023-06-29 21:19:27 logistdepo-db-1 | 2023-06-29T18:19:27.053627Z 2 [Note] Got packets out of order
2023-06-29 21:19:28 logistdepo-db-1 | 2023-06-29T18:19:28.098647Z 3 [Note] Got packets out of order
These are the commands I use on my code side.
version: '3'
services:
app:
build:
context: .
dockerfile: Dockerfile
image: laravel-app
ports:
- '8080:8080'
volumes:
- .:/var/www/html
depends_on:
- db
environment:
- DB_CONNECTION=mysql
- DB_HOST=db
- DB_PORT=3306
- DB_DATABASE=logistdepo
- DB_USERNAME=root
- DB_PASSWORD=
- PHP_OPCACHE_VALIDATE_TIMESTAMPS=0
db:
platform: linux/x86_64
image: mysql:5.7
ports:
- '3306:3306'
environment:
- MYSQL_DATABASE=Logist06
- MYSQL_ROOT_PASSWORD=myrootpassword
volumes:
- db-data:/var/lib/mysql
volumes:
db-data: