Package io.fathom.cloud.server.auth

Examples of io.fathom.cloud.server.auth.Auth$Domain


        DomainList response = new DomainList();
        response.domains = Lists.newArrayList();

        for (DomainData data : identityService.listDomains(user)) {
            Domain domain = toModel(data);
            response.domains.add(domain);
        }

        return response;
    }
View Full Code Here


        response.domain = toModel(data);
        return response;
    }

    private Domain toModel(DomainData data) {
        Domain model = new Domain();

        model.id = "" + data.getId();
        model.name = data.getName();

        model.description = data.getDescription();
View Full Code Here

        model.domain = toModel(domain);
        return model;
    }

    private Domain toModel(DomainData domain) {
        Domain model = new Domain();
        model.id = Long.toString(domain.getId());
        model.name = domain.getName();
        return model;
    }
View Full Code Here

    SecretService secretsService;

    @GET
    @Path("{id}")
    public Secret findSecret(@PathParam("id") long id) throws CloudException {
        Auth auth = getAuth();
        Project project = getProject();

        SecretService.Secret secret = secretsService.find(auth, project, id);
        notFoundIfNull(secret);
View Full Code Here

    }

    @GET
    @Path("{id}/{key}")
    public Response getSecret(@PathParam("id") long id, @PathParam("key") String key) throws CloudException {
        Auth auth = getAuth();
        Project project = getProject();

        SecretService.Secret secret = secretsService.find(auth, project, id);
        notFoundIfNull(secret);
View Full Code Here

        return Response.ok(data).build();
    }

    @GET
    public SecretList listSecrets() throws CloudException {
        Auth auth = getAuth();
        Project project = getProject();

        SecretList ret = new SecretList();
        ret.secrets = Lists.newArrayList();
View Full Code Here

        super("dns-zone-list");
    }

    @Override
    protected List<DnsZoneData> run0() throws Exception {
        Auth auth = getAuth();
        Project project = auth.getProject();

        List<DnsZone> zones = dns.listZones(project);
        return DnsZone.toData(zones);
    }
View Full Code Here

        super("dns-zone-delete");
    }

    @Override
    protected DnsZoneData run0() throws Exception {
        Auth auth = getAuth();
        Project project = auth.getProject();

        DnsZone found = dns.findZoneByName(project, zone);
        if (found == null) {
            throw new IllegalArgumentException("Zone not found: " + zone);
        }
View Full Code Here

        super("dns-record-create");
    }

    @Override
    protected DnsRecordsetData run0() throws Exception {
        Auth auth = getAuth();
        Project project = auth.getProject();

        DnsZone zone = dns.findMaximalZone(project, fqdn);
        if (zone == null) {
            throw new IllegalArgumentException("Cannot find matching zone");
        }
View Full Code Here

    @Inject
    SecretService secretService;

    @Override
    protected Message run0() throws Exception {
        Auth auth = getAuth();
        Project project = auth.getProject();

        secretService.deleteKey(auth, project, id);
        return null;
    }
View Full Code Here

TOP

Related Classes of io.fathom.cloud.server.auth.Auth$Domain

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.