Skip to content

Commit

Permalink
refactored
Browse files Browse the repository at this point in the history
Signed-off-by: munishchouhan <[email protected]>
  • Loading branch information
munishchouhan committed Jan 20, 2025
1 parent 887c9a7 commit ee99ce4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
9 changes: 4 additions & 5 deletions typespec/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
FROM nginx:alpine

# Copy the index.html and openapi.yaml to the Nginx html directory
COPY index.html /usr/share/nginx/html/
COPY tsp-output/@typespec/openapi3/openapi.yaml /usr/share/nginx/html/tsp-output/@typespec/openapi3/
# Copy index.html and openapi.yaml to the Nginx html directory
COPY index.html /usr/share/nginx/html/openapi/index.html
COPY tsp-output/@typespec/openapi3/openapi.yaml /usr/share/nginx/html/openapi/openapi.yaml

# Expose port 9080
EXPOSE 9080
EXPOSE 80

# Start Nginx when the container starts
CMD ["nginx", "-g", "daemon off;"]
2 changes: 1 addition & 1 deletion typespec/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<script>
window.onload = function() {
const ui = SwaggerUIBundle({
url: "tsp-output/@typespec/openapi3/openapi.yaml",
url: "openapi.yaml",
dom_id: '#swagger-ui',
presets: [
SwaggerUIBundle.presets.apis,
Expand Down

0 comments on commit ee99ce4

Please sign in to comment.