How to Update an Application Alias in OpenShift

import javax.ws.rs.client.Client;
import javax.ws.rs.client.ClientBuilder;
import javax.ws.rs.client.Entity;

import org.glassfish.jersey.client.authentication.HttpAuthenticationFeature;

public final class OpenShiftSample {

  public static void main(final String[] args) {
    final Client client = ClientBuilder.newClient();

    client.register(HttpAuthenticationFeature.basic("sampleUsername", "samplePassword"));

    client.target("https://host/broker/rest/domains/sampleDomain/applications/sampleApplication/aliases/sampleAlias").request().put(Entity.json(""));

    client.close();
  }

}
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s