-
Notifications
You must be signed in to change notification settings - Fork 432
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Bug] Service (Serve) changing port from 8000 to 9000 doesn't work (#…
…1081) Service (Serve) changing port from 8000 to 9000 doesn't work
- Loading branch information
1 parent
61adf56
commit 0cabd14
Showing
11 changed files
with
162 additions
and
35 deletions.
There are no files selected for viewing
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
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
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
99 changes: 99 additions & 0 deletions
99
ray-operator/config/samples/ray-service.different-port.yaml
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
# ray-service.different-port.yaml: By default, RayService exposes port 8000 to serve requests. This sample YAML | ||
# file demonstrates how to change the port to 9000. To achieve this, follow these steps: | ||
# (1) Modify `spec.serveConfig.port` to 9000. | ||
# (2) Modify the container `ray-head`'s `serve` port to 9000. | ||
apiVersion: ray.io/v1alpha1 | ||
kind: RayService | ||
metadata: | ||
name: rayservice-sample | ||
spec: | ||
serviceUnhealthySecondThreshold: 300 # Config for the health check threshold for service. Default value is 60. | ||
deploymentUnhealthySecondThreshold: 300 # Config for the health check threshold for deployments. Default value is 60. | ||
serveConfig: | ||
importPath: fruit.deployment_graph | ||
runtimeEnv: | | ||
working_dir: "https://github.com/ray-project/test_dag/archive/41d09119cbdf8450599f993f51318e9e27c59098.zip" | ||
deployments: | ||
- name: MangoStand | ||
numReplicas: 1 | ||
userConfig: | | ||
price: 3 | ||
rayActorOptions: | ||
numCpus: 0.1 | ||
- name: OrangeStand | ||
numReplicas: 1 | ||
userConfig: | | ||
price: 2 | ||
rayActorOptions: | ||
numCpus: 0.1 | ||
- name: PearStand | ||
numReplicas: 1 | ||
userConfig: | | ||
price: 1 | ||
rayActorOptions: | ||
numCpus: 0.1 | ||
- name: FruitMarket | ||
numReplicas: 1 | ||
rayActorOptions: | ||
numCpus: 0.1 | ||
- name: DAGDriver | ||
numReplicas: 1 | ||
routePrefix: "/" | ||
rayActorOptions: | ||
numCpus: 0.1 | ||
port: 9000 | ||
rayClusterConfig: | ||
rayVersion: '2.4.0' # should match the Ray version in the image of the containers | ||
######################headGroupSpecs################################# | ||
# Ray head pod template. | ||
headGroupSpec: | ||
# the following params are used to complete the ray start: ray start --head --block --redis-port=6379 ... | ||
rayStartParams: | ||
dashboard-host: '0.0.0.0' | ||
#pod template | ||
template: | ||
spec: | ||
containers: | ||
- name: ray-head | ||
image: rayproject/ray:2.4.0 | ||
resources: | ||
limits: | ||
cpu: 2 | ||
memory: 2Gi | ||
requests: | ||
cpu: 2 | ||
memory: 2Gi | ||
ports: | ||
- containerPort: 6379 | ||
name: gcs-server | ||
- containerPort: 8265 | ||
name: dashboard | ||
- containerPort: 10001 | ||
name: client | ||
- containerPort: 9000 | ||
name: serve | ||
workerGroupSpecs: | ||
# the pod replicas in this group typed worker | ||
- replicas: 1 | ||
minReplicas: 1 | ||
maxReplicas: 5 | ||
# logical group name, for this called small-group, also can be functional | ||
groupName: small-group | ||
rayStartParams: {} | ||
# Pod template | ||
template: | ||
spec: | ||
containers: | ||
- name: ray-worker # must consist of lower case alphanumeric characters or '-', and must start and end with an alphanumeric character (e.g. 'my-name', or '123-abc' | ||
image: rayproject/ray:2.4.0 | ||
lifecycle: | ||
preStop: | ||
exec: | ||
command: ["/bin/sh","-c","ray stop"] | ||
resources: | ||
limits: | ||
cpu: "1" | ||
memory: "2Gi" | ||
requests: | ||
cpu: "500m" | ||
memory: "2Gi" |
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
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
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
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
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
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
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