docker-compose

Apache docker container - Invalid command 'RewriteEngine'

纵然是瞬间 提交于 2019-12-31 10:41:28
问题 I use docker compose. However, when I run "docker-compose up", I came across an error : /var/www/html/.htaccess: Invalid command 'RewriteEngine'. Can you tell me where I fails ?? Project architecture : project-name / / docker-compose.yml / Dockerfile / apache.conf / php.ini / src / / index.php / .htaccess docker-compose.yml : web: build: . ports: - "80:80" volumes: - ./src:/var/www/html - php.ini:/usr/local/etc/php/conf.d/30-custom.ini - apache.conf:/etc/apache2/sites-enabled environment: -

Is it safe to clean docker/overlay2/

左心房为你撑大大i 提交于 2019-12-31 09:07:07
问题 I got some docker containers running on AWS EC2, the /var/lib/docker/overlay2 folder grows very fast in disk size. I'm wondering if it is safe to delete its content? or if docker has some kind of command to free up some disk usage. Thanks! UPDATE: I actually tried docker system prune -a already, which reclaimed 0Kb. Also my /docker/overlay2 disk size is much larger than the output from docker system df After reading docker documentation and BMitch's answer, I believe it is a stupid idea to

How to run wp cli in docker-compose.yml

我的未来我决定 提交于 2019-12-31 09:06:49
问题 Just starting in docker here So I got this in my docker-compose.yml 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: wordpress wordpress: depends_on: - db image: wordpress:latest ports: - 8000:80 restart: always environment: WORDPRESS_DB_HOST: db:3306 WORDPRESS_DB_NAME: wordpress WORDPRESS_DB_USER: wordpress WORDPRESS_DB_PASSWORD:

Docker - image operating system “windows” cannot be used on this platform

≡放荡痞女 提交于 2019-12-31 08:34:13
问题 I tried this on my Windows 10 machine: Dockerfile: From microsoft/nanoserver CMD ["echo", "Hello World"] PS C:\FSD\Docker\Trial1> docker build -t lea/leatest . Sending build context to Docker daemon 2.048kB Step 1/2 : FROM microsoft/nanoserver latest: Pulling from microsoft/nanoserver bce2fbc256ea: Pulling fs layer 58f68fa0ceda: Pulling fs layer image operating system "windows" cannot be used on this platform 回答1: Your Docker host is configured to run Linux containers inside of a VM. To run

How to clear the logs properly for a Docker container?

早过忘川 提交于 2019-12-31 08:04:29
问题 I use docker logs [container-name] to see the logs of a specific container. Is there an elegant way to clear these logs? 回答1: From this question there's a one-liner that you can run: echo "" > $(docker inspect --format='{{.LogPath}}' <container_name_or_id>) I'm not a big fan of modifying Docker's files directly with this, a truncate command, or log rotate, since each are external to docker. The external log deletion could happen while docker is writing json formatted data to the file,

Docker compose not building because of an error that has been removed

江枫思渺然 提交于 2019-12-31 07:16:06
问题 When I use the command docker-compose up in the directory that has the Docker compose Dockerfile, I am hit with the error below. The error was that in acp times app there was an extra brace, which I removed. When I try to run the container again I get the same error message, why is this? I am new to docker, if any additional info is needed to help solve the problem let me know, I'm not even sure what I am looking for, I followed the docker docks simple instructions. Could it be that something

Linked docker-compose containers making http requests

*爱你&永不变心* 提交于 2019-12-31 05:03:25
问题 I've been looking on the web for a while and haven't found a solution to my problem which is similar to this StackOverflow question Docker HTTP-requests between containers. But this answer is already what I'm doing in my computer. I'm providing my docker-compose file version: "3" services: web: image: ecdavis15/tsn-web-server ports: - "3000:3000" links: - app app: image: ecdavis15/tsn-app-server ports: - "3030:3030" links: - mongo mongo: image: mongo ports: - "27017:27017" volumes: - ./data

HTTPS-Redirect with Traefik behind Aws Loadbalancer

谁说我不能喝 提交于 2019-12-31 03:48:08
问题 I'm trying to redirect all incoming Traefik from http to https, for a web application which gets served out of a docker container with a custom port. If I build this docker compose file, and scale the application everything works as expected. I'm able to request http and https of the application, but I try to accomplish that only https get served and http gets redirected to https. Since I use a Docker-Compose file, I don't have a Traefik.toml, and try to accomplish this without one. Docker

Docker Compose WordPress Volumes Appear Empty

我的未来我决定 提交于 2019-12-31 01:52:28
问题 I'm trying to set up a simple WordPress build using docker compose. However, when I build it, the volumes appear to be empty. Here is my docker-compose.yml: version: '3' services: wordpress: image: wordpress restart: always ports: - 8000:80 volumes: - ./development:/var/www/html environment: WORDPRESS_DB_HOST: db WORDPRESS_DB_NAME: wordpress WORDPRESS_DB_USER: root WORDPRESS_DB_PASSWORD: password depends_on: - db networks: - wordpress-network phpmyadmin: image: phpmyadmin/phpmyadmin:latest

Using Docker compose within Google App Engine

怎甘沉沦 提交于 2019-12-30 17:46:30
问题 I am currently experimenting with the Google App Engine flexible environment , especially the feature allowing you to build custom runtimes by providing a Dockerfile. Docker provides a really nice feature called docker-compose for defining and running multi-container Docker applications. Now the question is, is there any way one can use the power of docker-compose within GAE? If the answer is no, what would be the best approach for deploying a multi-container application (for instance Nginx +