webfly通过docker-compose添加管理员用户

时间:2019-07-24 13:19:12

标签: java docker docker-compose wildfly

我如何在docker-compose文件中添加run命令以为Jboss / wildfly启用管理员用户,我的docker-compose文件在以下位置:

version: "3"
services:
  user:
    image: jboss/wildfly
    ports:
      - 8080:8080
      - 8000:8000
      - 9990:9990
    volumes:
      - ./User/target/:/opt/jboss/wildfly/standalone/deployments/
    container_name: "user"
    restart: always
    command: >
         bash -c "/opt/jboss/wildfly/bin/add-user.sh admin Admin#007 --silent
         && /opt/jboss/wildfly/bin/standalone.sh -b 0.0.0.0 -bmanagement 0.0.0.0"

参考:http://blog.arungupta.me/wildfly-admin-console-docker-image-techtip66/

但是我仍然看到以下屏幕提示我添加用户。

enter image description here

0 个答案:

没有答案