Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
80 commits
Select commit Hold shift + click to select a range
a8e62ff
add spring cloud service
peizhou298 Aug 20, 2019
aac837f
fix help and params syntax error
peizhou298 Aug 20, 2019
77c69e9
use relative path instead of file name when upload file
peizhou298 Aug 20, 2019
345eeca
add service binding
peizhou298 Aug 21, 2019
736f948
use autopep8 format code
peizhou298 Aug 21, 2019
e396848
change binding cosmosdb update function
peizhou298 Aug 21, 2019
c1bbbfb
didn't remove app when create app failed
peizhou298 Aug 21, 2019
014c214
use nginx image for app default deployment
peizhou298 Aug 21, 2019
06e594e
merge with distributed version to use default nginx jar
peizhou298 Aug 22, 2019
4219f96
fix wording in custom.py
yucwan Aug 29, 2019
5f52b01
Merge pull request #1 from yucwan/patch-1
peizhou298 Aug 29, 2019
ddb9b82
use latest sdk
peizhou298 Aug 29, 2019
e7f6e4b
add config server and service binding
peizhou298 Aug 30, 2019
ec2b8e2
use new version
peizhou298 Aug 30, 2019
0e0d07e
remove mvnw mvn in
peizhou298 Aug 31, 2019
29ca9a9
change app create behavior
peizhou298 Sep 3, 2019
ed3e38b
show deployment when show app
peizhou298 Sep 3, 2019
412ad2b
add test-endpoint command
peizhou298 Sep 3, 2019
6b60af0
remove redundant print
peizhou298 Sep 3, 2019
6c10536
fix validate key syntax error
peizhou298 Sep 3, 2019
45cdd85
change namespace to appplatform
peizhou298 Sep 9, 2019
2f8a3f2
change default deployment name to default
peizhou298 Sep 10, 2019
2a9a17c
change extension from asc to spring-cloud
peizhou298 Sep 18, 2019
77acc16
fix test-endpoint list format
peizhou298 Sep 18, 2019
8ea7ace
fix some prompt information
peizhou298 Sep 19, 2019
ff60310
Update _help.py
yucwan Sep 20, 2019
2d1ffc7
Update _params.py
yucwan Sep 20, 2019
03929c0
Update _help.py
yucwan Sep 20, 2019
bf9d368
Update custom.py
yucwan Sep 20, 2019
811ca48
Merge pull request #4 from yucwan/patch-6
peizhou298 Sep 20, 2019
562df4d
add config server git command group
peizhou298 Sep 20, 2019
b875097
remove tags in deployment create/deploy
peizhou298 Sep 20, 2019
6d90bdf
merge with dev for yuchen's PR
peizhou298 Sep 20, 2019
9557e40
use resource-group's location when creating service if not specified
peizhou298 Sep 20, 2019
5552253
remove extra test
peizhou298 Sep 20, 2019
ea88a9d
set app update cpu, memory,count to None to avoid default value
peizhou298 Sep 25, 2019
509f28c
add skip clone settings
peizhou298 Sep 25, 2019
021a48e
fix config server none type bugs
peizhou298 Sep 26, 2019
c39ae9b
fix deployment help errors
peizhou298 Sep 27, 2019
a2109fe
CLI review change
peizhou298 Sep 27, 2019
ab4aa76
add prompt for after successfully upload jar package
peizhou298 Sep 27, 2019
423d28d
add spring cloud in index.json and use blob url
peizhou298 Sep 27, 2019
f89796e
check config server null before get it's inside property
peizhou298 Sep 27, 2019
5f85d45
update index.json for spring-cloud
peizhou298 Sep 27, 2019
d775727
use sdk's enum type
peizhou298 Sep 30, 2019
4221ea4
convert lcoation from display name to proper name
peizhou298 Sep 30, 2019
874aa6b
update index.json
peizhou298 Sep 30, 2019
aebeb84
update index.json
peizhou298 Sep 30, 2019
6c969e3
format table output
peizhou298 Oct 15, 2019
81d1137
remove reduent None juge
peizhou298 Oct 15, 2019
452027e
remove spring-cloud in index.json
peizhou298 Oct 16, 2019
2064e57
Merge branch 'master' into peizhou/ChangeExtensionName
peizhou298 Oct 16, 2019
cfd4322
format code with autopep8
peizhou298 Oct 16, 2019
8f713e0
Merge branch 'peizhou/ChangeExtensionName' of https://github.com/VSCh…
peizhou298 Oct 16, 2019
72508d0
fix style check error
peizhou298 Oct 17, 2019
0b74df4
replace old sdk with new sdk from offical repo
peizhou298 Oct 17, 2019
61a3ceb
fix CI check warnings
peizhou298 Oct 17, 2019
dcbbb9d
disable worng import error check
peizhou298 Oct 17, 2019
360264d
add code owners for spring-cloud
peizhou298 Oct 17, 2019
5828734
code owners
peizhou298 Oct 17, 2019
0982ebc
CI: add missed liscense headers
peizhou298 Oct 17, 2019
38656e5
add runtime-version, jvm-options and env settings in app create
peizhou298 Oct 21, 2019
96c8386
Merge branch 'master' into peizhou/ChangeExtensionName
Oct 24, 2019
d50f01f
remove unnecessary changes outside spring-cloud
peizhou298 Oct 25, 2019
d4647a6
remove upper limit of cli core version
peizhou298 Oct 25, 2019
78728db
Merge branch 'peizhou/ChangeExtensionName' of https://github.com/VSCh…
peizhou298 Oct 25, 2019
52696fc
add upper Azure cli version 2.1.0 and raise exception in show-deploy-…
peizhou298 Oct 25, 2019
96338f1
Merge branch 'master' into peizhou/ChangeExtensionName
Oct 25, 2019
447f422
use new Python sdk
peizhou298 Oct 28, 2019
ec5c21c
Merge branch 'peizhou/ChangeExtensionName' of https://github.com/VSCh…
peizhou298 Oct 28, 2019
eb8c7e8
Remove extra changes out-side spring-cloud
peizhou298 Oct 28, 2019
a297982
add new line int fronnt door customer.py
peizhou298 Oct 28, 2019
ba3a1b2
fronnt-door
peizhou298 Oct 28, 2019
41850d4
add spring-cloud in index.json
peizhou298 Oct 28, 2019
49f36cc
Merge branch 'master' into peizhou/ChangeExtensionName
Oct 28, 2019
3a252ba
fix issues from online CI
peizhou298 Oct 29, 2019
ee372aa
Merge branch 'peizhou/ChangeExtensionName' of https://github.com/VSCh…
peizhou298 Oct 29, 2019
43612cb
change app create function with the change of sdk from synv to async
peizhou298 Oct 30, 2019
3fc75fb
remove spring-cloud from index.json
peizhou298 Oct 30, 2019
84271b5
Merge branch 'master' into peizhou/ChangeExtensionName
Oct 30, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 18 additions & 14 deletions src/spring-cloud/azext_spring_cloud/_help.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,17 +69,17 @@
short-summary: Create a new app with a default deployment in the Azure Spring Cloud.
examples:
- name: Create an app with the default configuration.
text: az spring-cloud app create -n MyApp -s Myspring-cloud
text: az spring-cloud app create -n MyApp -s MyCluster -g MyResourceGroup
- name: Create an public accessible app with 3 instances and 2 cpu cores and 3 GB of memory per instance.
text: az spring-cloud app create -n MyApp -s Myspring-cloud --is-public true --cpu 2 --memory 3 --instance-count 3
text: az spring-cloud app create -n MyApp -s MyCluster -g MyResourceGroup --is-public true --cpu 2 --memory 3 --instance-count 3
"""

helps['spring-cloud app update'] = """
type: command
short-summary: Update configurations of an app.
examples:
- name: Add an environment variable for the app.
text: az spring-cloud app update --env foo=bar
text: az spring-cloud app update -n MyApp -s MyCluster -g MyResourceGroup --env foo=bar
"""

helps['spring-cloud app delete'] = """
Expand All @@ -92,7 +92,7 @@
short-summary: List all apps in the Azure Spring Cloud.
examples:
- name: Query status of persistent storage of all apps
text: az asc app list -s Myspring-cloud -o json --query '[].{Name:name, PersistentStorage:properties.persistentDisk}'
text: az spring-cloud app list -s MyCluster -g MyResourceGroup -o json --query '[].{Name:name, PersistentStorage:properties.persistentDisk}'
"""

helps['spring-cloud app show'] = """
Expand Down Expand Up @@ -120,21 +120,21 @@
short-summary: Deploy source code or pre-built binary to an app and update related configurations.
examples:
- name: Deploy source code to an app. This will pack current directory, build binary with Pivotal Build Service and then deploy to the app.
text: az spring-cloud app deploy -n MyApp -s Myspring-cloud
text: az spring-cloud app deploy -n MyApp -s MyCluster -g MyResourceGroup
- name: Deploy a pre-built jar to an app with jvm options and environment variables.
text: az spring-cloud app deploy -n MyApp -s Myspring-cloud --jar-path app.jar --jvm-options="-XX:+UseG1GC -XX:+UseStringDeduplication" --env foo=bar
text: az spring-cloud app deploy -n MyApp -s MyCluster -g MyResourceGroup --jar-path app.jar --jvm-options="-XX:+UseG1GC -XX:+UseStringDeduplication" --env foo=bar
- name: Deploy source code to a specific deployment of an app.
text: az spring-cloud app deploy -n MyApp -s Myspring-cloud -d green-deployment
text: az spring-cloud app deploy -n MyApp -s MyCluster -g MyResourceGroup -d green-deployment
"""

helps['spring-cloud app scale'] = """
type: command
short-summary: Manually scale an app or its deployments.
examples:
- name: Scale up an app to 4 cpu cores and 8 Gb of memory per instance.
text: az spring-cloud app scale -n MyApp -s Myspring-cloud --cpu 3 --memory 8
text: az spring-cloud app scale -n MyApp -s MyCluster -g MyResourceGroup --cpu 3 --memory 8
- name: Scale out a deployment of the app to 5 instances.
text: az spring-cloud app scale -n MyApp -s Myspring-cloud -d green-deployment --instance-count 5
text: az spring-cloud app scale -n MyApp -s MyCluster -g MyResourceGroup -d green-deployment --instance-count 5
"""

helps['spring-cloud app show-deploy-log'] = """
Expand All @@ -147,7 +147,7 @@
short-summary: Set production deployment of an app.
examples:
- name: Swap a staging deployment of an app to production.
text: az spring-cloud app set-deployment -d green-deployment -n MyApp -s Myspring-cloud
text: az spring-cloud app set-deployment -d green-deployment -n MyApp -s MyCluster -g MyResourceGroup
"""

helps['spring-cloud app deployment'] = """
Expand Down Expand Up @@ -175,9 +175,9 @@
short-summary: Create a staging deployment for the app. To deploy code or update setting to an existing deployment, use az spring-cloud app deploy/update --deployment <staging deployment>.
examples:
- name: Deploy source code to a new deployment of an app. This will pack current directory, build binary with Pivotal Build Service and then deploy.
text: az spring-cloud app deployment create -n green-deployment --app MyApp -s Myspring-cloud
text: az spring-cloud app deployment create -n green-deployment --app MyApp -s MyCluster -g MyResourceGroup
- name: Deploy a pre-built jar to an app with jvm options and environment variables.
text: az spring-cloud app deployment create -n green-deployment --app MyApp -s Myspring-cloud --jar-path app.jar --jvm-options="-XX:+UseG1GC -XX:+UseStringDeduplication" --env foo=bar
text: az spring-cloud app deployment create -n green-deployment --app MyApp -s MyCluster -g MyResourceGroup --jar-path app.jar --jvm-options="-XX:+UseG1GC -XX:+UseStringDeduplication" --env foo=bar
"""

helps['spring-cloud config-server'] = """
Expand Down Expand Up @@ -205,6 +205,10 @@
short-summary: Commands to manage Config Server git property in Azure Spring Cloud.
"""

helps['spring-cloud config-server git repo'] = """
type: group
short-summary: Commands to manage Config Server git repository in Azure Spring Cloud.
"""

helps['spring-cloud config-server git set'] = """
type: command
Expand All @@ -221,7 +225,7 @@
short-summary: Remove an existing repositry of git property of Config Server.
"""

helps['spring-cloud config-server git repo update'] = """
helps['spring-cloud config-server git repo update'] = """
type: command
short-summary: Override an existing repositry of git property of Config Server, will totally override the old one.
"""
Expand Down Expand Up @@ -269,7 +273,7 @@
short-summary: Bind an Azure Cosmos DB with the app.
examples:
- name: Bind an Azure Cosmos DB.
text: az spring-cloud app binding cosmos create -n mysqlProduction --app MyApp --resource-id ${COSMOSDB_ID} --api-type mongo --database mymongo
text: az spring-cloud app binding cosmos add -n cosmosProduction --app MyApp --resource-id ${COSMOSDB_ID} --api-type mongo --database mymongo
"""

helps['spring-cloud app binding cosmos update'] = """
Expand Down
2 changes: 1 addition & 1 deletion src/spring-cloud/azext_spring_cloud/_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def load_arguments(self, _):
with self.argument_context(scope) as c:
c.argument('key', help='API key of the service.')
c.argument('username', help='Username of the database')
c.argument('database_name')
c.argument('database_name', help='Database name')

for scope in ['spring-cloud app binding redis add', 'spring-cloud app binding redis update']:
with self.argument_context(scope) as c:
Expand Down
7 changes: 6 additions & 1 deletion src/spring-cloud/azext_spring_cloud/custom.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,12 @@ def app_create(cmd, client, resource_group, service, name,

active_deployment = client.deployments.get(
resource_group, service, name, DEFAULT_DEPLOYMENT_NAME)
app = client.apps.update(resource_group, service, name, properties)
poller = client.apps.update(resource_group, service, name, properties)
logger.info("Waiting for the app update completion")
while poller.done() is False:
sleep(5)

app = client.apps.get(resource_group, service, name)
app.active_deployment = active_deployment
return app

Expand Down