mirror of
https://github.com/sourcegraph/sourcegraph.git
synced 2026-02-06 18:51:59 +00:00
Encountered this error while doing my demo
```
{"SeverityText":"ERROR","Timestamp":1718110348252114099,"InstrumentationScope":"mi2.instance.create","Caller":"mi2/instance.go:478","Function":"main.glob..func26","Body":"new instance validation failed: slug (displayName) must be between 4 to 30 characters. Allowed characters are: lowercase letters, numbers, hyphen. Current: christoph-resolve-syntactic-symbol-at-request-range","Resource":{"service.name":"mi2","service.version":"2024-06-11-09-50-
```
So now we limit it to 30 chars and print a notice to inform the user
that it has been truncated
## Test plan
Tested locally
```
go run ./dev/sg cloud eph deploy --name 'christoph-resolve-syntactic-symbol-at-request-range_277899_2024-06-11_5.4-f04d3b973a19' --version 'christoph-resolve-syntactic-symbol-at-request-range_277899_2024-06-11_5.4-f04d3b973a19'
✅ Version "christoph-resolve-syntactic-symbol-at-request-range_277899_2024-06-11_5.4-f04d3b973a19" found in Cloud ephemeral registry
👉 Your deployment name has been truncated to be "christoph-resolve-syntactic-sy"
```
## Changelog
- sg - set a max length for cloud ephemeral deployment names
|
||
|---|---|---|
| .. | ||
| buf | ||
| ci | ||
| cloudsqlproxy | ||
| dependencies | ||
| internal | ||
| interrupt | ||
| linters | ||
| msp | ||
| root | ||
| sams | ||
| .gitignore | ||
| analytics.go | ||
| bootstrap.sh | ||
| BUILD.bazel | ||
| checks.go | ||
| Dockerfile | ||
| generates.go | ||
| live.go | ||
| main_test.go | ||
| main.go | ||
| os.go | ||
| OWNERS | ||
| README.md | ||
| sg_analytics.go | ||
| sg_audit.go | ||
| sg_backport.go | ||
| sg_bazel.go | ||
| sg_cloud.go | ||
| sg_cody_gateway.go | ||
| sg_db.go | ||
| sg_deploy.go | ||
| sg_doctor.go | ||
| sg_embeddings_qa.go | ||
| sg_generate.go | ||
| sg_help.go | ||
| sg_images_test.go | ||
| sg_images.go | ||
| sg_insights.go | ||
| sg_install.go | ||
| sg_lint.go | ||
| sg_live.go | ||
| sg_logo.go | ||
| sg_migration.go | ||
| sg_monitoring.go | ||
| sg_ops.go | ||
| sg_page.go | ||
| sg_rfc.go | ||
| sg_run.go | ||
| sg_secret.go | ||
| sg_security.go | ||
| sg_setup.go | ||
| sg_src.go | ||
| sg_start_test.go | ||
| sg_start.go | ||
| sg_teammate.go | ||
| sg_telemetry.go | ||
| sg_tests.go | ||
| sg_update.go | ||
| sg_version.go | ||
| sg_wolfi.go | ||
| sg.config.example.yaml | ||
| sg.doctor.yaml | ||
| VISION.md | ||
sg - the Sourcegraph developer tool
_____ _____
/\ \ /\ \
/::\ \ /::\ \
/::::\ \ /::::\ \
/::::::\ \ /::::::\ \
/:::/\:::\ \ /:::/\:::\ \
/:::/__\:::\ \ /:::/ \:::\ \
\:::\ \:::\ \ /:::/ \:::\ \
___\:::\ \:::\ \ /:::/ / \:::\ \
/\ \:::\ \:::\ \ /:::/ / \:::\ ___\
/::\ \:::\ \:::\____\/:::/____/ ___\:::| |
\:::\ \:::\ \::/ /\:::\ \ /\ /:::|____|
\:::\ \:::\ \/____/ \:::\ /::\ \::/ /
\:::\ \:::\ \ \:::\ \:::\ \/____/
\:::\ \:::\____\ \:::\ \:::\____\
\:::\ /:::/ / \:::\ /:::/ /
\:::\/:::/ / \:::\/:::/ /
\::::::/ / \::::::/ /
\::::/ / \::::/ /
\::/ / \::/____/
\/____/
sg is the CLI tool that Sourcegraph developers can use to develop Sourcegraph.
Learn more about it here.