This commit is contained in:
parent
c679ac24c6
commit
a1d55fb1ca
3 changed files with 10 additions and 0 deletions
|
@ -16,6 +16,9 @@ spec:
|
|||
containers:
|
||||
- name: silly-game
|
||||
image: forgejo.edf-bootstrap.cx.fg1.ffm.osc.live/devfw-cicd/michals-silly-game-backend:main
|
||||
env:
|
||||
- name: DOMAIN
|
||||
value: "{{{ .Env.DOMAIN }}}"
|
||||
ports:
|
||||
- containerPort: 8080
|
||||
volumeMounts:
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
package de.telekom.silly_game;
|
||||
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.Collections;
|
||||
|
@ -17,8 +18,12 @@ public class GameController {
|
|||
|
||||
private AtomicInteger jumpCount = new AtomicInteger(0);
|
||||
|
||||
@Value("${domain}")
|
||||
private String domain;
|
||||
|
||||
@GetMapping("/jump")
|
||||
public Map<String, Integer> registerJump() {
|
||||
System.out.println(domain);
|
||||
int total = jumpCount.incrementAndGet();
|
||||
total = total/2;
|
||||
System.out.println(total);
|
||||
|
|
|
@ -9,4 +9,6 @@ spring.mail.properties.mail.smtp.starttls.enable=false
|
|||
|
||||
cors.allowed-origin=*
|
||||
|
||||
domain=${DOMAIN}
|
||||
|
||||
server.servlet.context-path=/silly-game-api
|
Loading…
Reference in a new issue