Skip to content

Commit 1696cc7

Browse files
committed
change path for docs in s3
1 parent 5d1b318 commit 1696cc7

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ current_aws_account := $(shell aws sts get-caller-identity --query Account --out
88

99
src_directory_root = src/
1010
dist_ui_directory_root = dist_ui/
11-
dist_docs_directory_root = dist/swagger/
1211
integration_test_directory_root = tests/live_integration/
1312

1413
# CHANGE ME (as needed)

src/api/createSwagger.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const html = `
1919
<script>
2020
window.onload = () => {
2121
window.ui = SwaggerUIBundle({
22-
url: '/swagger/openapi.json',
22+
url: '/docs/openapi.json',
2323
dom_id: '#swagger-ui',
2424
});
2525
};
@@ -37,7 +37,7 @@ async function createSwaggerFiles() {
3737
console.log("App is ready. Generating specs...");
3838
const __filename = fileURLToPath(import.meta.url);
3939
const __dirname = path.dirname(__filename);
40-
const outputDir = path.resolve(__dirname, "..", "..", "dist_ui", "swagger");
40+
const outputDir = path.resolve(__dirname, "..", "..", "dist_ui", "docs");
4141
await mkdir(outputDir, { recursive: true });
4242
const jsonSpec = JSON.stringify(app.swagger(), null, 2);
4343
const yamlSpec = app.swagger({ yaml: true });

src/api/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -218,13 +218,13 @@ async function init(prettyPrint: boolean = false, initClients: boolean = true) {
218218
if (isRunningInLambda && !isSwaggerServer) {
219219
// Serve docs from S3
220220
app.get("/api/documentation", (_request, response) => {
221-
response.redirect("/swagger/index.html", 308);
221+
response.redirect("/docs/index.html", 308);
222222
});
223223
app.get("/api/documentation/json", (_request, response) => {
224-
response.redirect("/swagger/openapi.json", 308);
224+
response.redirect("/docs/openapi.json", 308);
225225
});
226226
app.get("/api/documentation/yaml", (_request, response) => {
227-
response.redirect("/swagger/openapi.yaml", 308);
227+
response.redirect("/docs/openapi.yaml", 308);
228228
});
229229
}
230230
if (!runEnvironments.includes(process.env.RunEnvironment as RunEnvironment)) {

0 commit comments

Comments
 (0)