Last active
January 31, 2023 16:20
-
-
Save Neutrollized/7d92a891a9cbd75c980e7658f587e967 to your computer and use it in GitHub Desktop.
Medium: Migrating off of Pivotal Cloud Foundry? Consider HashiCorp Nomad!
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
job "spring-backend" { | |
datacenters = ["gcp-test"] | |
priority = 80 | |
group "spring-backend" { | |
network { | |
port "api" { static = 8081 } | |
} | |
task "spring-backend" { | |
driver = "java" | |
config { | |
jar_path = "rest-0.0.1-SNAPSHOT.jar" | |
jvm_options = ["-Xmx512M", "-Xms512M"] | |
args = ["--server.port=${NOMAD_PORT_api}"] | |
} | |
resources { | |
cpu = 500 | |
memory = 640 | |
} | |
artifact { | |
source = "https://storage.googleapis.com/public-file-server/rest-0.0.1-SNAPSHOT.jar" | |
mode = "file" | |
destination = "rest-0.0.1-SNAPSHOT.jar" | |
} | |
service { | |
name = "spring-backend" | |
provider = "nomad" | |
port = "api" | |
tags = ["spring", "backend"] | |
} | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment