Hello and thanks for your reply. Today I started running the setup, I thought it would be a good idea to delete the created "docker networks". So I started to stop and remove the whole running containers and docker networks.
sudo docker network prune
Now the setup is not working.
sudo docker-compose up
Creating network "wp-local-test-zero_mynet" with the default driver
Starting wp-local-test-zero_db_1 ... error
ERROR: for wp-local-test-zero_db_1 Cannot start service db: network e0201ea69f1b4c38194c34acfc49e1e2c7e542dae7c7b2947de6b74bfbace53c not found
ERROR: for db Cannot start service db: network e0201ea69f1b4c38194c34acfc49e1e2c7e542dae7c7b2947de6b74bfbace53c not found
ERROR: Encountered errors while bringing up the project.
Note: I have previously, successfully changed the DB name, username, passwords and it worked, with above bugs.
Edit: After this post, I rebooted the system and I still get the above mentioned error.
When running:
sudo docker network ls
I see a few networks. I'm unable to remove them simply by "docker network rm <network> " command
NETWORK ID NAME DRIVER SCOPE
67a0fdd09fb9 bridge bridge local
046ad4f5d62f host host local
06cc4ef3ea41 none null local
I assume the setup is trying to find a docker related network that it should have created it in the first place, or there are 3 running networks that I'm failing to stop. lol. I don't know what happened. any suggestions appreciated before I reinstall docker.
EDIT 2:
I tried the " -a " option as some online search suggested.
sudo docker container ls -a
And what a mess. A long list of containers that do not appear in a normal "container ls" command. I manually removed them all. Then ran the docker-compose.YML (the setup) again. now back to point zero.
EDIT 3:
I ran the setup and here we are again. Without the chmod wordpress is unable to upload image to the site.
then I added the following line to the end of docker-compose.yml:
command: chown -R www-data:www-data /var/www/html/wp-content/
and again the error:
sudo docker-compose up
[sudo] password for sage:
Starting wp-local-test-zero_db_1 ... done
Starting wp-local-test-zero_phpmyadmin_1 ... done
Recreating wp-local-test-zero_wordpress_1 ... done
Attaching to wp-local-test-zero_db_1, wp-local-test-zero_phpmyadmin_1, wp-local-test-zero_wordpress_1
db_1 | 2022-05-19 13:58:03+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 5.7.37-1debian10 started.
phpmyadmin_1 | AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.18.0.3. Set the 'ServerName' directive globally to suppress this message
db_1 | 2022-05-19 13:58:03+00:00 [Note] [Entrypoint]: Switching to dedicated user 'mysql'
phpmyadmin_1 | AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.18.0.3. Set the 'ServerName' directive globally to suppress this message
db_1 | 2022-05-19 13:58:03+00:00 [Note] [Entrypoint]: Entrypoint script for MySQL Server 5.7.37-1debian10 started.
phpmyadmin_1 | [Thu May 19 13:58:04.030698 2022] [mpm_prefork:notice] [pid 1] AH00163: Apache/2.4.52 (Debian) PHP/8.0.15 configured -- resuming normal operations
phpmyadmin_1 | [Thu May 19 13:58:04.030780 2022] [core:notice] [pid 1] AH00094: Command line: 'apache2 -D FOREGROUND'
db_1 | 2022-05-19T13:58:03.742533Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
db_1 | 2022-05-19T13:58:03.745000Z 0 [Note] mysqld (mysqld 5.7.37) starting as process 1 ...
db_1 | 2022-05-19T13:58:03.749712Z 0 [Note] InnoDB: PUNCH HOLE support available
db_1 | 2022-05-19T13:58:03.749747Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
db_1 | 2022-05-19T13:58:03.749757Z 0 [Note] InnoDB: Uses event mutexes
db_1 | 2022-05-19T13:58:03.749765Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
db_1 | 2022-05-19T13:58:03.749772Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
db_1 | 2022-05-19T13:58:03.749781Z 0 [Note] InnoDB: Using Linux native AIO
db_1 | 2022-05-19T13:58:03.750278Z 0 [Note] InnoDB: Number of pools: 1
db_1 | 2022-05-19T13:58:03.750443Z 0 [Note] InnoDB: Using CPU crc32 instructions
db_1 | 2022-05-19T13:58:03.753047Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
db_1 | 2022-05-19T13:58:03.769836Z 0 [Note] InnoDB: Completed initialization of buffer pool
db_1 | 2022-05-19T13:58:03.773576Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
db_1 | 2022-05-19T13:58:03.786812Z 0 [Note] InnoDB: Highest supported file format is Barracuda.
db_1 | 2022-05-19T13:58:03.811229Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables
db_1 | 2022-05-19T13:58:03.811458Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ...
db_1 | 2022-05-19T13:58:03.884411Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
db_1 | 2022-05-19T13:58:03.885707Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active.
db_1 | 2022-05-19T13:58:03.885729Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active.
db_1 | 2022-05-19T13:58:03.886527Z 0 [Note] InnoDB: 5.7.37 started; log sequence number 14804964
db_1 | 2022-05-19T13:58:03.886681Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool
db_1 | 2022-05-19T13:58:03.887016Z 0 [Note] Plugin 'FEDERATED' is disabled.
db_1 | 2022-05-19T13:58:03.891522Z 0 [Note] InnoDB: Buffer pool(s) load completed at 220519 13:58:03
db_1 | 2022-05-19T13:58:03.896239Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them.
db_1 | 2022-05-19T13:58:03.896262Z 0 [Note] Skipping generation of SSL certificates as certificate files are present in data directory.
db_1 | 2022-05-19T13:58:03.896269Z 0 [Warning] A deprecated TLS version TLSv1 is enabled. Please use TLSv1.2 or higher.
db_1 | 2022-05-19T13:58:03.896277Z 0 [Warning] A deprecated TLS version TLSv1.1 is enabled. Please use TLSv1.2 or higher.
db_1 | 2022-05-19T13:58:03.896985Z 0 [Warning] CA certificate ca.pem is self signed.
db_1 | 2022-05-19T13:58:03.897039Z 0 [Note] Skipping generation of RSA key pair as key files are present in data directory.
db_1 | 2022-05-19T13:58:03.897601Z 0 [Note] Server hostname (bind-address): '*'; port: 3306
db_1 | 2022-05-19T13:58:03.898007Z 0 [Note] IPv6 is available.
db_1 | 2022-05-19T13:58:03.898031Z 0 [Note] - '::' resolves to '::';
db_1 | 2022-05-19T13:58:03.898083Z 0 [Note] Server socket created on IP: '::'.
db_1 | 2022-05-19T13:58:03.899904Z 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.
db_1 | 2022-05-19T13:58:03.920484Z 0 [Note] Event Scheduler: Loaded 0 events
db_1 | 2022-05-19T13:58:03.920761Z 0 [Note] mysqld: ready for connections.
db_1 | Version: '5.7.37' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server (GPL)
wp-local-test-zero_wordpress_1 exited with code 0
wp-local-test-zero_wordpress_1 exited with code 0
wp-local-test-zero_wordpress_1 exited with code 0
wp-local-test-zero_wordpress_1 exited with code 0
wp-local-test-zero_wordpress_1 exited with code 0
wp-local-test-zero_wordpress_1 exited with code 0
wp-local-test-zero_wordpress_1 exited with code 0
wp-local-test-zero_wordpress_1 exited with code 0
^CGracefully stopping... (press Ctrl+C again to force)