-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #25 from MGTheTrain/feature/rest-api
Feature/rest api
- Loading branch information
Showing
61 changed files
with
3,386 additions
and
422 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,4 +22,8 @@ go.work | |
go.work.sum | ||
|
||
# env file | ||
.env | ||
.env | ||
|
||
# tmp files | ||
*.tmp | ||
*.temp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
{ | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
|
||
{ | ||
"name": "Launch Package", | ||
"type": "go", | ||
"request": "launch", | ||
"mode": "auto", | ||
"program": "${fileDirname}", | ||
"env": { | ||
"PORT": "8080", | ||
"DATABASE_TYPE": "postgres", | ||
"DATABASE_DSN": "user=postgres password=postgres host=localhost port=5432 sslmode=disable", | ||
"DATABASE_NAME": "meta", | ||
"BLOB_CONNECTOR_CLOUD_PROVIDER": "azure", | ||
"BLOB_CONNECTOR_CONNECTION_STRING": "DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;", | ||
"BLOB_CONNECTOR_CONTAINER_NAME": "blobs", | ||
"KEY_CONNECTOR_CLOUD_PROVIDER": "azure", | ||
"KEY_CONNECTOR_CONNECTION_STRING": "DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;", | ||
"KEY_CONNECTOR_CONTAINER_NAME": "keys", | ||
"LOGGER_LOG_LEVEL": "info", | ||
"LOGGER_LOG_TYPE": "console", | ||
"LOGGER_FILE_PATH": "", | ||
"PKCS11_MODULE_PATH": "/usr/lib/softhsm/libsofthsm2.so", | ||
"PKCS11_SO_PIN": "123456", | ||
"PKCS11_USER_PIN": "234567", | ||
"PKCS11_SLOT_ID": "0x0" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# If you prefer the allow list template instead of the deny list, see community template: | ||
# https://github.com/github/gitignore/blob/main/community/Golang/Go.AllowList.gitignore | ||
# | ||
# Binaries for programs and plugins | ||
*.exe | ||
*.exe~ | ||
*.dll | ||
*.so | ||
*.dylib | ||
|
||
# Test binary, built with `go test -c` | ||
*.test | ||
|
||
# Output of the go coverage tool, specifically when used with LiteIDE | ||
*.out | ||
|
||
# Dependency directories (remove the comment below to include it) | ||
# vendor/ | ||
|
||
# Go workspace file | ||
go.work | ||
go.work.sum | ||
|
||
# env file | ||
.env | ||
|
||
# tmp files | ||
*.tmp | ||
*.temp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Build stage | ||
FROM golang:1.21-alpine AS build | ||
|
||
WORKDIR /app | ||
|
||
RUN apk update | ||
COPY go.mod go.sum ./ | ||
RUN go mod tidy | ||
COPY . . | ||
RUN go build -o crypto_vault_service ./cmd/crypto-vault-service/crypto_vault_service.go | ||
|
||
# Serve stage | ||
FROM alpine:latest | ||
|
||
WORKDIR /root/ | ||
|
||
RUN apk update && apk add --no-cache libc6-compat | ||
COPY --from=build /app/crypto_vault_service . | ||
|
||
EXPOSE 8080 | ||
|
||
ENTRYPOINT ["./crypto_vault_service"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.