Created
June 29, 2016 21:46
-
-
Save gastaldi/6297a75617afed6618ce52ddcd1113db to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.wildfly.swarm.management.console; | |
import org.wildfly.swarm.management.ManagementFraction; | |
import org.wildfly.swarm.spi.api.Fraction; | |
import org.wildfly.swarm.spi.api.annotations.Configuration; | |
/** | |
* Created by ggastald on 29/06/16. | |
*/ | |
@Configuration | |
public class ManagementConsoleFraction implements Fraction { | |
@Override | |
public void postInitialize(PostInitContext initContext) { | |
boolean management = initContext.hasFraction("Management"); | |
if (management) { | |
ManagementFraction fraction = (ManagementFraction) initContext.fraction("Management"); | |
fraction.httpInterfaceManagementInterface(iface -> iface.consoleEnabled(true)); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment