-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #166 from devatherock/no-auth
feat: Added support for anonymous access
- Loading branch information
Showing
16 changed files
with
196 additions
and
45 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,3 +19,4 @@ checkstyle.xml | |
codenarc.xml | ||
logs-intg.txt | ||
logs-intg-remote.txt | ||
logs-intg-no-auth.txt |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
version: '3.7' | ||
services: | ||
|
||
ldap-search-api: | ||
image: devatherock/ldap-search-api:${DOCKER_TAG:-latest} | ||
container_name: ldap-search-api-intg-no-auth | ||
network_mode: "host" | ||
environment: | ||
LDAP_HOST: ldap://localhost:33389 | ||
LDAP_AUTH_TYPE: none | ||
LOGBACK_CONFIGURATION_FILE: logback-json.xml | ||
JACKSON_SERIALIZATION_INDENT_OUTPUT: true | ||
|
||
health: | ||
image: alpine:3.21.0 | ||
network_mode: "host" | ||
depends_on: | ||
- ldap-search-api | ||
healthcheck: | ||
test: ["CMD", "wget", "-q", "-O", "-", "http://localhost:8080/health"] | ||
interval: 2s | ||
timeout: 60s | ||
retries: 30 | ||
command: | | ||
sh -c ' | ||
wget -q -O - http://localhost:8080/health | ||
sleep 120 | ||
' |
7 changes: 6 additions & 1 deletion
7
...y/io.github.devatherock/ldapsearch.controllers/LdapSearchControllerIntegrationSpec.groovy
This file contains 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
29 changes: 29 additions & 0 deletions
29
...ithub.devatherock/ldapsearch.controllers/LdapSearchControllerNoAuthIntegrationSpec.groovy
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package io.github.devatherock.ldapsearch.controllers | ||
|
||
import io.micronaut.test.extensions.spock.annotation.MicronautTest | ||
|
||
/** | ||
* Integration test for {@link LdapSearchController} without auth | ||
*/ | ||
@MicronautTest(propertySources = 'classpath:application-integration.yml', startApplication = false) | ||
class LdapSearchControllerNoAuthIntegrationSpec extends LdapSearchControllerSpec { | ||
|
||
protected String getExpectedJson() { | ||
''' | ||
[ | ||
{ | ||
"userPassword" : "YWJjZGU=", | ||
"uid" : "sclaus", | ||
"objectClass" : [ | ||
"top", | ||
"person", | ||
"organizationalPerson", | ||
"inetOrgPerson" | ||
], | ||
"sn" : "Claus", | ||
"cn" : "Santa Claus" | ||
} | ||
] | ||
'''.stripIndent().trim() | ||
} | ||
} |
This file contains 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
Oops, something went wrong.