Skip to content

Commit 355fdfc

Browse files
committed
Rename app.yaml to cortex.yaml
1 parent a7f8032 commit 355fdfc

File tree

19 files changed

+18
-18
lines changed

19 files changed

+18
-18
lines changed

build/test-examples.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ set -eou pipefail
1919
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")"/.. >/dev/null && pwd)"
2020
CORTEX="$ROOT/bin/cortex"
2121

22-
for example in $ROOT/examples/*/app.yaml; do
22+
for example in $ROOT/examples/*/cortex.yaml; do
2323
timer=1200
2424
example_base_dir=$(dirname "${example}")
2525
retry="false"

cli/cmd/deploy.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ var deployCmd = &cobra.Command{
4747

4848
func deploy(force bool, ignoreCache bool) {
4949
root := mustAppRoot()
50-
_, err := appNameFromConfig() // Check proper app.yaml
50+
_, err := appNameFromConfig() // Check proper cortex.yaml
5151
if err != nil {
5252
errors.Exit(err)
5353
}

cli/cmd/errors.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,6 @@ func ErrorFailedToConnect(urlStr string) error {
123123
func ErrorCliNotInAppDir() error {
124124
return Error{
125125
Kind: ErrCliNotInAppDir,
126-
message: "your current working directory is not in or under a cortex app directory (identified via a top-level app.yaml file)",
126+
message: "your current working directory is not in or under a cortex app directory (identified via a top-level cortex.yaml file)",
127127
}
128128
}

cli/cmd/init.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ func writeFile(subPath string, content string, root string, createdFiles []strin
7979

8080
func appInitFiles(appName string) map[string]string {
8181
return map[string]string{
82-
"app.yaml": fmt.Sprintf("- kind: app\n name: %s\n", appName),
82+
"cortex.yaml": fmt.Sprintf("- kind: app\n name: %s\n", appName),
8383

8484
"resources/environments.yaml": `## Sample environment:
8585
#

cli/cmd/lib_config_reader.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ func appRootOrBlank() string {
3333
errors.Exit(err)
3434
}
3535
for true {
36-
if err := files.CheckFile(filepath.Join(dir, "app.yaml")); err == nil {
36+
if err := files.CheckFile(filepath.Join(dir, "cortex.yaml")); err == nil {
3737
return dir
3838
}
3939
if dir == "/" {
@@ -91,7 +91,7 @@ func allConfigPaths(root string) []string {
9191

9292
func appNameFromConfig() (string, error) {
9393
appRoot := mustAppRoot()
94-
return userconfig.ReadAppName(filepath.Join(appRoot, "app.yaml"), "app.yaml")
94+
return userconfig.ReadAppName(filepath.Join(appRoot, "cortex.yaml"), "cortex.yaml")
9595
}
9696

9797
func AppNameFromFlagOrConfig() (string, error) {

docs/applications/advanced/python-packages.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ Cortex allows you to install additional Python packages that can be made availab
44

55
## PyPI Packages
66

7-
Cortex looks for a `requirements.txt` file in the top level directory of the app (in the same level as `app.yaml`). All packages listed in `requirements.txt` will be made available to aggregators, transformers, and estimators.
7+
Cortex looks for a `requirements.txt` file in the top level directory of the app (in the same level as `cortex.yaml`). All packages listed in `requirements.txt` will be made available to aggregators, transformers, and estimators.
88

99
```text
1010
./iris/
11-
├── app.yaml
11+
├── cortex.yaml
1212
├── requirements.txt
1313
├── samples.json
1414
├── implementations/
@@ -23,7 +23,7 @@ Cortex App Directory
2323

2424
```text
2525
./iris/
26-
├── app.yaml
26+
├── cortex.yaml
2727
├── samples.json
2828
├── implementations/
2929
├── resources/

docs/applications/resources/app.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Application
22

3-
The app resource is used to group a set of resources into an application that can be deployed as a singular unit. It must be defined in every Cortex application directory in a top-level `app.yaml` file.
3+
The app resource is used to group a set of resources into an application that can be deployed as a singular unit. It must be defined in every Cortex application directory in a top-level `cortex.yaml` file.
44

55
## Config
66

docs/applications/resources/overview.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Cortex applications consist of declarative resource configuration written in YAM
1616

1717
Resources can reference other resources from within their configuration (e.g. when defining input values) by prefixing the other resource's name with an `@` symbol. For example, a model may specify `input: @column1`, which denotes that a resource named "column1" is an input to this model.
1818

19-
With the exception of the `app` kind (which must be defined in a top-level `app.yaml` file), resources may be defined in any YAML file within your Cortex application folder or any subdirectories.
19+
With the exception of the `app` kind (which must be defined in a top-level `cortex.yaml` file), resources may be defined in any YAML file within your Cortex application folder or any subdirectories.
2020

2121
The `cortex deploy` command will validate all resource configuration and attempt to create the requested state on the cluster.
2222

docs/tutorial.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ Our goal is to build a web API that returns the type of iris given its measureme
2222

2323
```bash
2424
mkdir iris && cd iris
25-
touch app.yaml irises.json
25+
touch cortex.yaml irises.json
2626
```
2727

28-
Cortex requires an `app.yaml` file which defines an `app` resource. Other resources may be defined in arbitrarily named YAML files in the the directory which contains `app.yaml` or any subdirectories. For this example, we will define all of our resources in `app.yaml`.
28+
Cortex requires an `cortex.yaml` file which defines an `app` resource. Other resources may be defined in arbitrarily named YAML files in the the directory which contains `cortex.yaml` or any subdirectories. For this example, we will define all of our resources in `cortex.yaml`.
2929

30-
Add to `app.yaml`:
30+
Add to `cortex.yaml`:
3131

3232
```yaml
3333
- kind: app
@@ -36,7 +36,7 @@ Add to `app.yaml`:
3636
3737
#### Configure data ingestion
3838
39-
Add to `app.yaml`:
39+
Add to `cortex.yaml`:
4040

4141
```yaml
4242
# Environments
@@ -55,7 +55,7 @@ Cortex is able to read from any S3 bucket that your AWS credentials grant access
5555

5656
This configuration will generate a training dataset with the specified columns and train our classifier using the generated dataset. Here we're using a built-in estimator (which uses TensorFlow's [DNNClassifier](https://www.tensorflow.org/api_docs/python/tf/estimator/DNNClassifier)) but Cortex supports any TensorFlow code that adheres to the [tf.estimator API](https://www.tensorflow.org/guide/estimators).
5757

58-
Add to `app.yaml`:
58+
Add to `cortex.yaml`:
5959

6060
```yaml
6161
# Models
@@ -78,7 +78,7 @@ Add to `app.yaml`:
7878

7979
This will make the model available as a live web service that can serve real-time predictions.
8080

81-
Add to `app.yaml`:
81+
Add to `cortex.yaml`:
8282

8383
```yaml
8484
# APIs
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

pkg/operator/api/userconfig/errors.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ func ErrorReadConfig() error {
245245
func ErrorMissingAppDefinition() error {
246246
return Error{
247247
Kind: ErrMissingAppDefinition,
248-
message: fmt.Sprintf("app.yaml must define an app resource"),
248+
message: fmt.Sprintf("cortex.yaml must define an app resource"),
249249
}
250250
}
251251

0 commit comments

Comments
 (0)