Skip to content

Commit

Permalink
correct header and api call
Browse files Browse the repository at this point in the history
  • Loading branch information
Guiiz94 committed Apr 25, 2024
1 parent 77078fe commit 3fdb4f5
Show file tree
Hide file tree
Showing 14 changed files with 779 additions and 653 deletions.
Binary file modified .DS_Store
Binary file not shown.
6 changes: 6 additions & 0 deletions api/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ FROM golang:1.21-alpine AS builder
# Installation de git, nécessaire pour récupérer les modules Go et Swaggo.
RUN apk add --no-cache git

# Installation des certificats CA, cruciaux pour les appels HTTPS.
RUN apk add --no-cache ca-certificates

# Installation de Swag CLI pour la documentation Swagger.
RUN go install github.com/swaggo/swag/cmd/swag@latest

Expand Down Expand Up @@ -34,6 +37,9 @@ COPY --from=builder /api/apiserver /
COPY --from=builder /api/.env /
COPY --from=builder /api/docs /docs

# Copie des certificats CA.
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/

# Exposition du port sur lequel le serveur API s'exécute.
EXPOSE 5000

Expand Down
4 changes: 4 additions & 0 deletions api/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package main

import (
"log"

"github.com/MTthoas/dex/api/configs"
_ "github.com/MTthoas/dex/api/docs"
"github.com/MTthoas/dex/api/middleware"
Expand All @@ -14,10 +15,13 @@ import (

func main() {


err := godotenv.Load()
if err != nil {
log.Fatal("Error loading .env file")
}
print(err)

config := configs.FiberConfig()

app := fiber.New(config)
Expand Down
Loading

0 comments on commit 3fdb4f5

Please sign in to comment.