Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
DIDComm Connector
Manage
Activity
Members
Labels
Plan
Issues
29
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Harbor Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Eclipse Projects
xfsc
Common Services
DIDComm Connector
Commits
faff8983
Commit
faff8983
authored
1 year ago
by
Steffen Schulze
Browse files
Options
Downloads
Patches
Plain Diff
logging changed and dockerfile
parent
740cf4c6
No related branches found
Branches containing commit
No related tags found
1 merge request
!10
Refactoring
Pipeline
#40602
passed with warnings with stages
in 2 minutes and 35 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
deployment/docker/Dockerfile
+1
-1
1 addition, 1 deletion
deployment/docker/Dockerfile
internal/config/config.go
+5
-5
5 additions, 5 deletions
internal/config/config.go
with
6 additions
and
6 deletions
deployment/docker/Dockerfile
+
1
−
1
View file @
faff8983
...
...
@@ -22,7 +22,7 @@ WORKDIR /src
# copy lib from rust build
RUN
mkdir
-p
didcomm/lib
COPY
--from=rust-build /src/uniffi/target/release/libdidcomm_uniffi.* didcomm/lib/
COPY
./cmd/api/config.yaml /config.yaml
#RUN go build to build the application with the name app
RUN
GOOS
=
linux
GOARCH
=
amd64 go build
-o
/src/app ./cmd/api/
...
...
This diff is collapsed.
Click to expand it.
internal/config/config.go
+
5
−
5
View file @
faff8983
...
...
@@ -69,19 +69,23 @@ var env string
func
LoadConfig
()
error
{
setDefaults
()
Logger
.
Info
(
"Read config"
)
readConfig
()
if
err
:=
viper
.
Unmarshal
(
&
CurrentConfiguration
);
err
!=
nil
{
return
err
}
Logger
.
Info
(
"Set ENV"
)
setEnvironment
()
if
err
:=
checkMode
();
err
!=
nil
{
return
err
}
if
err
:=
setLogLevel
();
err
!=
nil
{
return
err
}
Logger
.
Info
(
"Check Resolver"
)
err
:=
checkResolver
(
CurrentConfiguration
.
DidComm
.
ResolverUrl
)
if
err
!=
nil
{
Logger
.
Error
(
"Resolver not available"
,
"msg"
,
err
)
...
...
@@ -99,11 +103,6 @@ func LoadConfig() error {
b
,
err
:=
json
.
Marshal
(
CurrentConfiguration
)
if
err
!=
nil
{
Logger
.
Error
(
"Error marshalling config for logging"
,
"config"
,
err
)
return
err
}
Logger
.
Info
(
string
(
b
))
if
err
!=
nil
{
...
...
@@ -167,6 +166,7 @@ func setEnvironment() {
}
func
setLogLevel
()
(
err
error
)
{
Logger
.
Info
(
"Set Log Level"
)
logLevel
:=
new
(
slog
.
LevelVar
)
switch
strings
.
ToLower
(
CurrentConfiguration
.
LogLevel
)
{
case
"debug"
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment