Docker Curl(7): error; cannot access pages from dashboard
-
I have a WordPress docker container with mysql 5.7 set up for local development using docker-compose on mac.
The problem is that I can’t access my pages through the dashboard. They are not editable there, and none are selectable as ‘static’ pages. The only page viewable is the ‘sample’ page.
This is the error:
The REST API request failed due to an error.
Error: [] cURL error 7: Failed to connect to localhost port 8000: Connection refusedI’ve tried adding
define( ‘ALTERNATE_WP_CRON’, true );define( ‘WP_CRON_LOCK_TIMEOUT’, 1 );
to the wp-config.php file, as per the instructions here: https://kb.wprssaggregator.com/article/120-issues-with-cron-jobs.I have also tried adding new pages to the default themes as well. No luck.
I deleted all plugins and custom themes at one point, as well.
There also doesn’t seem to be anything wrong with the cron events being scheduled.I am able to update and view the theme I am creating through port:8000 and add plugins. However, none of my pages are viewable in the dashboard.
Being pretty new to docker and wordpress, I’m hoping someone might have an answer or be able to shed some light on the situation.
Here is my yml file:
version: ‘3.3’
services:
db:
image: mysql:5.7
volumes:
– db_data:/var/lib/mysql
restart: always
environment:
MYSQL_ROOT_PASSWORD: somewordpress
MYSQL_DATABASE: wordpress
MYSQL_USER: wordpress
MYSQL_PASSWORD: wordpresswordpress:
depends_on:
– db
image: wordpress:latest
volumes:
– ./wp-content:/var/www/html/wp-content
ports:
– “8000:80”
restart: always
environment:
WORDPRESS_DB_HOST: db:3306
WORDPRESS_DB_USER: wordpress
WORDPRESS_DB_PASSWORD: wordpress
WORDPRESS_DB_NAME: wordpress
WP_DEBUG: 1
volumes:
db_data:
The topic ‘Docker Curl(7): error; cannot access pages from dashboard’ is closed to new replies.