docker redis 设置密码


version: "3"
services: 
  redis:
    image: redis
    container_name: redis
    ports: 
      - 6379:6379
    command: redis-server --requirepass 123456
  php: 
    restart: always
    image: registry.cn-hangzhou.aliyuncs.com/php_public/php 
    container_name: php 
    volumes: 
    - ./nginx/www:/var/www/html
    - ./php_conf:/usr/local/etc/php/conf.d
    links: 
      - redis:redis
    stdin_open: true
    tty: true
  nginx: 
    restart: always
    image: nginx
    links:
      - php
    ports: 
    - 80:80
    volumes: 
    - ./nginx/www:/usr/share/nginx/html:ro
    - ./nginx/conf/conf.d:/etc/nginx/conf.d:ro

  


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM