{"record":{"id":"1671a2f8a71abcd8","repo":"quarkusio/quarkus","slug":"auth-config-file-not-found-path","errorCode":null,"errorMessage":"Auth config file not found: ${path}","messagePattern":"Auth config file not found: (.+?)","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"extensions/azure-functions/deployment/src/main/java/io/quarkus/azure/functions/deployment/AzureFunctionsConfig.java","lineNumber":256,"sourceCode":"         * Tenant ID required if using <i>oauth2</i> or <i>device_code</i> type\n         */\n        Optional<String> tenant();\n\n        private static String findValue(Properties props, String key) {\n            if (props.contains(key))\n                return (String) props.get(key);\n            return (String) props.get(\"quarkus.azure-functions.auth.\" + key);\n        }\n\n        private static AuthConfiguration fromFile(Optional<String> path) {\n            try {\n                if (path.isEmpty()) {\n                    throw new IllegalArgumentException(\"Path must be set if using file auth config\");\n\n                }\n                File file = new File(path.get());\n                if (!file.exists()) {\n                    throw new IllegalArgumentException(\"Auth config file not found: \" + path.get());\n                }\n                Properties props = new Properties();\n                props.load(new FileInputStream(file));\n                String typeVal = findValue(props, \"type\");\n                if (typeVal == null) {\n                    throw new IllegalArgumentException(\"Auth config file does not define type: \" + path);\n                }\n                final AuthType type = AuthType.parseAuthType(typeVal);\n                final AuthConfiguration authConfiguration = new AuthConfiguration(type);\n                authConfiguration.setClient(findValue(props, \"client\"));\n                authConfiguration.setTenant(findValue(props, \"tenant\"));\n                authConfiguration.setCertificate(findValue(props, \"certificate\"));\n                authConfiguration.setCertificatePassword(findValue(props, \"certificate-password\"));\n                authConfiguration.setKey(findValue(props, \"key\"));\n\n                authConfiguration.setEnvironment(findValue(props, \"environment\"));\n                authConfiguration.setEnvironment(Optional.ofNullable(authConfiguration.getEnvironment())\n                        .orElseGet(() -> AzureEnvironmentUtils.azureEnvironmentToString(AzureEnvironment.AZURE)));","sourceCodeStart":238,"sourceCodeEnd":274,"githubUrl":"https://github.com/quarkusio/quarkus/blob/e1c734241f34c7919086ceb4c9262b4a58f6de44/extensions/azure-functions/deployment/src/main/java/io/quarkus/azure/functions/deployment/AzureFunctionsConfig.java#L238-L274","documentation":"When the Azure Functions plugin is configured to load auth settings from a properties file, fromFile checks that the given file exists before parsing. If the path is set but points to a missing file, it throws IllegalArgumentException with the resolved path. The deployment cannot authenticate to Azure without it.","triggerScenarios":"quarkus.azure-functions.auth.path points to a file that does not exist at the time quarkus:deploy runs — wrong relative path, file deleted, or CI working directory differs from local.","commonSituations":"Relative paths resolving against a different working directory in CI; auth file excluded from the repo and not generated; typo in filename or extension; running from a submodule directory.","solutions":["Verify the path is correct relative to the Maven working directory; prefer ${project.basedir} in pom.xml","Ensure the auth file is generated/checked out before the deploy phase in CI","List the directory to confirm the file exists with the exact name and case"],"exampleFix":"<!-- before -->\n<quarkus.azure-functions.auth.path>azure.auth.properties</quarkus.azure-functions.auth.path>\n<!-- after -->\n<quarkus.azure-functions.auth.path>${project.basedir}/src/main/azure/azure.auth.properties</quarkus.azure-functions.auth.path>","handlingStrategy":"validation","validationCode":"Path auth = Paths.get(authPath);\nif (!Files.isRegularFile(auth)) {\n  throw new IllegalStateException(\"Auth config file missing: \" + auth.toAbsolutePath());\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Use ${project.basedir} in pom paths to avoid CWD dependence","Ensure the auth file is generated before the deploy phase in CI pipelines","Commit a template of the auth file (without secrets) to catch path drift early"],"tags":["azure-functions","configuration","file-not-found"],"backgroundTag":"config-file-not-found","analyzedSha":"e1c734241f34c7919086ceb4c9262b4a58f6de44","analyzedAt":"2026-09-05T17:01:29.979Z","contentChangedAt":"2026-09-05T17:01:29.979Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}