e62795798d
Add a new driver capability: RemoteTasks. When a task is run by a driver with RemoteTasks set, its TaskHandle will be propagated to the server in its allocation's TaskState. If the task is replaced due to a down node or draining, its TaskHandle will be propagated to its replacement allocation. This allows tasks to be scheduled in remote systems whose lifecycles are disconnected from the Nomad node's lifecycle. See https://github.com/hashicorp/nomad-driver-ecs for an example ECS remote task driver.
22 lines
707 B
JSON
22 lines
707 B
JSON
[
|
|
{
|
|
"command": [
|
|
"/bin/sh -c \"echo '<html> <head> <title>Amazon ECS Sample App</title> <style>body {margin-top: 40px; background-color: #333;} </style> </head><body> <div style=color:white;text-align:center> <h1>Amazon ECS Sample App</h1> <h2>Congratulations!</h2> <p>Your application is now running on a container in Amazon ECS.</p> </div></body></html>' > /usr/local/apache2/htdocs/index.html && httpd-foreground\""
|
|
],
|
|
"entryPoint": [
|
|
"sh",
|
|
"-c"
|
|
],
|
|
"essential": true,
|
|
"image": "httpd:2.4",
|
|
"name": "nomad-remote-driver-demo",
|
|
"portMappings": [
|
|
{
|
|
"containerPort": 80,
|
|
"hostPort": 80,
|
|
"protocol": "tcp"
|
|
}
|
|
]
|
|
}
|
|
]
|