Skip to content

Commit

Permalink
updating mythic-cli labels and logging
Browse files Browse the repository at this point in the history
  • Loading branch information
its-a-feature committed Feb 13, 2024
1 parent 7ee5676 commit a706381
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 1 deletion.
6 changes: 6 additions & 0 deletions Mythic_CLI/Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## 0.2.16 - 2024-02-13

### Changed

- Updated the default values for docker-compose to add back in labels and names

## 0.2.15 - 2024-02-12

### Changed
Expand Down
2 changes: 1 addition & 1 deletion Mythic_CLI/src/cmd/config/vars.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ package config

var (
// Version Mythic CLI version
Version = "v0.2.15"
Version = "v0.2.16"
)
14 changes: 14 additions & 0 deletions Mythic_CLI/src/cmd/internal/serviceMetadata.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,22 @@ func AddMythicService(service string) {
if _, ok := pStruct["environment"]; !ok {
pStruct["environment"] = []interface{}{}
}
pStruct["labels"] = map[string]string{
"name": service,
}
pStruct["hostname"] = strings.ToLower(service)
pStruct["logging"] = map[string]interface{}{
"driver": "json-file",
"options": map[string]string{
"max-file": "1",
"max-size": "10m",
},
}
pStruct["restart"] = config.GetMythicEnv().GetString("global_restart_policy")
pStruct["container_name"] = strings.ToLower(service)
mythicEnv := config.GetMythicEnv()
volumes, _ := manager.GetManager().GetVolumes()

switch service {
case "mythic_postgres":
if mythicEnv.GetBool("postgres_use_build_context") {
Expand Down

0 comments on commit a706381

Please sign in to comment.