Skip to content
Snippets Groups Projects
Commit dc0d3618 authored by Ole Voldsæter's avatar Ole Voldsæter
Browse files

refs meta#143 swagger-ui + omorganisering

parent 3de3f6ea
No related branches found
No related tags found
No related merge requests found
...@@ -28,10 +28,7 @@ deploy: ...@@ -28,10 +28,7 @@ deploy:
--capabilities CAPABILITY_IAM --capabilities CAPABILITY_IAM
- aws s3 rm "s3://${STACK_NAME}.aws.uib.no" --recursive - aws s3 rm "s3://${STACK_NAME}.aws.uib.no" --recursive
- aws s3 sync dist/ "s3://${STACK_NAME}.aws.uib.no" --delete - aws s3 sync dist/ "s3://${STACK_NAME}.aws.uib.no" --delete
- aws s3api put-object --bucket "${STACK_NAME}.aws.uib.no" - aws s3 sync api-static/ "s3://${STACK_NAME}.aws.uib.no" --delete
--key api/index.html
--body api_static/index.html
--content-type "text/html;charset=UTF-8"
- DISTRO_ID=$(aws cloudformation describe-stack-resource - DISTRO_ID=$(aws cloudformation describe-stack-resource
--stack-name ${STACK_NAME} --stack-name ${STACK_NAME}
--logical-resource-id Distribution --logical-resource-id Distribution
......
<! <!DOCTYPE html>
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en" dir="ltr"> <html lang="en" dir="ltr">
<head> <head>
...@@ -6,6 +5,7 @@ ...@@ -6,6 +5,7 @@
<title></title> <title></title>
</head> </head>
<body> <body>
Halloen! <h1>Beta - REST-API for ordbok.uib.no</h1>
<a href="swagger-ui.html">Utforsk APIen</a>
</body> </body>
</html> </html>
<!-- HTML for static distribution bundle build -->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Swagger UI</title>
<link rel="stylesheet" type="text/css" href="https://unpkg.com/browse/swagger-ui-dist@3.23.5/swagger-ui.css" >
<link rel="icon" type="image/png" href="https://unpkg.com/browse/swagger-ui-dist@3.23.5/favicon-32x32.png" sizes="32x32" />
<link rel="icon" type="image/png" href="https://unpkg.com/browse/swagger-ui-dist@3.23.5/favicon-16x16.png" sizes="16x16" />
<style>
html
{
box-sizing: border-box;
overflow: -moz-scrollbars-vertical;
overflow-y: scroll;
}
*,
*:before,
*:after
{
box-sizing: inherit;
}
body
{
margin:0;
background: #fafafa;
}
</style>
</head>
<body>
<div id="swagger-ui"></div>
<script src="https://unpkg.com/browse/swagger-ui-dist@3.23.5/swagger-ui-bundle.js"> </script>
<script src="https://unpkg.com/browse/swagger-ui-dist@3.23.5/swagger-ui-standalone-preset.js"> </script>
<script>
window.onload = function() {
// Begin Swagger UI call region
const ui = SwaggerUIBundle({
url: "./swagger.json",
dom_id: '#swagger-ui',
deepLinking: true,
presets: [
SwaggerUIBundle.presets.apis,
SwaggerUIStandalonePreset
],
plugins: [
SwaggerUIBundle.plugins.DownloadUrl
],
layout: "StandaloneLayout"
})
// End Swagger UI call region
window.ui = ui
}
</script>
</body>
</html>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment