Skip to content

Commit

Permalink
Create secrets profile and config file
Browse files Browse the repository at this point in the history
  • Loading branch information
schnapster committed Dec 10, 2023
1 parent 64ebabe commit 4bcadc3
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ gradle-app.setting
# End of https://www.gitignore.io/api/git,java,linux,gradle,intellij+iml


baymax.yaml
baymax-secrets.yaml
application.yaml
logs/
*.sqlite
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion docker/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ services:
- 127.0.0.1:5005:5005 # Remote debug
# - 127.0.0.1:8849:8849 # JProfiler
volumes:
- "./baymax.yaml:/opt/baymax/baymax.yaml:ro"
- "./baymax-secrets.yaml:/opt/baymax/baymax-secrets.yaml:ro"
- "./models:/opt/baymax/models:ro"
- "./logs:/opt/baymax/logs"
- "./logs/gc:/opt/baymax/logs/gc"
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/space/npstr/baymax/Launcher.java
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ public static void main(String[] args) {

System.setProperty("spring.config.name", "baymax");
SpringApplication app = new SpringApplication(Launcher.class);
app.setAdditionalProfiles("secrets");

app.addListeners(
event -> {
if (event instanceof ApplicationEnvironmentPreparedEvent) {
Expand Down
33 changes: 33 additions & 0 deletions src/main/resources/baymax.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
spring:
output:
ansi:
enabled: always
main:
banner-mode: log

logging:
file.name: './logs/baymax.log'
file.max-history: 30
file.max-size: 1GB

level:
root: INFO
space.npstr: TRACE

sentry:
dsn: ""

baymax:
status-type: 1
status-message: ""
staff-role-ids:
- 479601466110377984 # Staff in Aki's Lair
- 340205944866865162 # Moderators in Wolfia
- 321115861924446208 # Botfather in Wolfia
help-desks:
- channel-id: 487947091960659969
model-name: aki
model-uri: "https://raw.githubusercontent.com/CapybaraLabs/aki-wiki/master/baymax_model.yaml"
- channel-id: 634144815709290510
model-name: wolfia
model-uri: "https://raw.githubusercontent.com/wolfiabot/baymax_helpdesk/master/baymax_helpdesk.yaml"

0 comments on commit 4bcadc3

Please sign in to comment.