Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Marchp1s and add back Identity #57

Merged
merged 179 commits into from
Apr 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
179 commits
Select commit Hold shift + click to select a range
a8eb7d7
Skeleton code
calvinsID Feb 3, 2022
c2963ce
az containerapp env show
calvinsID Feb 3, 2022
e461384
List kube/managed environments
calvinsID Feb 3, 2022
b5e9381
Create kube environment, wait doesn't work yet
calvinsID Feb 4, 2022
23ca42f
Update containerapp stubs (check if it is supported now)
calvinsID Feb 4, 2022
919ed4e
Containerapp env delete, polling not working yet
calvinsID Feb 4, 2022
f1d2d0c
Added polling for create and delete
calvinsID Feb 4, 2022
22ecb09
Use Microsoft.App RP for show, list, delete command
calvinsID Feb 5, 2022
e756d4e
Create containerapp env using Microsoft.App RP
calvinsID Feb 6, 2022
3392755
Add optional containerapp env create arguments
calvinsID Feb 8, 2022
ef13ece
Remove old kube environment code, naming fixes
calvinsID Feb 8, 2022
eeb4c8b
Containerapp create almost done
calvinsID Feb 11, 2022
12cf40c
Done containerapp create, except for --yaml. Need to test
calvinsID Feb 11, 2022
509b91c
Containerapp show, list
calvinsID Feb 11, 2022
e60ad9d
Fix helptext
calvinsID Feb 11, 2022
b99c054
Containerapp delete
calvinsID Feb 11, 2022
f538a24
Containerapp update. Needs secrets api to be implemented, and testing
calvinsID Feb 14, 2022
25e8e1a
Add scale command
calvinsID Feb 14, 2022
4cce2e8
Various validations, small fixes
calvinsID Feb 15, 2022
074e1ad
listSecrets API for updates, autogen log analytics for env
calvinsID Feb 18, 2022
e1f2bfc
Use space delimiter for secrets and env variables
calvinsID Feb 24, 2022
8d36f9a
Verify sub is registered to Microsoft.ContainerRegistration if creati…
calvinsID Feb 25, 2022
725a841
Containerapp create --yaml
calvinsID Feb 23, 2022
f6479f1
Fix updating registry to do create or update
calvinsID Feb 23, 2022
c98d02c
Fix containerapp update command. Add image-name parameter to support …
calvinsID Feb 23, 2022
b581786
started update with --yaml. Need to do create or update for when an a…
calvinsID Feb 23, 2022
1a8b598
use space delimiter for startup_command and args, instead of comma de…
calvinsID Feb 24, 2022
51be4de
Traffic weights
calvinsID Mar 1, 2022
1b3bb9c
List and show revisions
calvinsID Feb 24, 2022
00602b6
az containerapp revision restart, activate, deactivate
calvinsID Feb 24, 2022
d034188
Add ability for users to clear args/command in az containerapp update
calvinsID Mar 3, 2022
788bb3f
Various fixes, traffic weights fixes
calvinsID Mar 3, 2022
a5acf07
Verify subnet subscription is registered to Microsoft.ContainerServices
calvinsID Mar 4, 2022
9b66d17
GitHub Actions Update (#17)
runefa Mar 8, 2022
a12c86d
Remove --location since location must be same as managed env
calvinsID Mar 8, 2022
d561c46
Add options for flag names: --env-vars and --registry-srever
calvinsID Mar 8, 2022
dd3d799
Empty string to clear env_vars
calvinsID Mar 8, 2022
ea87b77
Default revisions_mode to single
calvinsID Mar 8, 2022
44edebb
Infer acr credentials if it is acr and credentials are not provided
calvinsID Mar 8, 2022
6ae589c
fix help msg
calvinsID Mar 8, 2022
47e49f3
if image is hosted on acr, and no registry server is supplied, infer …
calvinsID Mar 9, 2022
5b58d6f
Added subgroups (Ingress, Registry, Secret) and updated revisions (#18)
runefa Mar 11, 2022
3fa18df
More p0 fixes (#20)
calvinsID Mar 11, 2022
c72c29e
Update help text (#21)
anthonychu Mar 14, 2022
c09fe39
New 1.0.1 version
calvinsID Mar 14, 2022
d264bbf
Added identity commands + --assign-identity flag to containerapp crea…
runefa Mar 14, 2022
77c742d
Dapr Commands (#23)
runefa Mar 14, 2022
3394781
Rename --image-name to --container-name
calvinsID Mar 14, 2022
d406c0b
Remove allowInsecure since it was messing with the api parsing
calvinsID Mar 14, 2022
551ea0d
Fix for env var being empty string
calvinsID Mar 14, 2022
f7cd94d
Rename to --dapr-instrumentation-key, only infer ACR credentials if -…
calvinsID Mar 14, 2022
fa4be8a
Remove az containerapp scale
calvinsID Mar 14, 2022
e5ddac4
Fix delete containerapp errors
calvinsID Mar 14, 2022
b0c6f95
Remove ingress, dapr flags from az containerapp update/revision copy
calvinsID Mar 14, 2022
8e30e91
Fix revision list -o table
calvinsID Mar 14, 2022
013507f
Help text fix
calvinsID Mar 14, 2022
32ed50b
Bump extension to 0.1.2
calvinsID Mar 14, 2022
5c99446
Update managed identities and Dapr help text (#25)
anthonychu Mar 15, 2022
ddc07c0
Env var options + various bug fixes (#26)
runefa Mar 16, 2022
5fe8e5f
Fixed style issues, various bug fixes (#27)
runefa Mar 18, 2022
87a6101
Update src/containerapp/azext_containerapp/tests/latest/test_containe…
runefa Mar 18, 2022
8f4b5c6
Specific Error Types + Bugfixes (Help, remove app-subnet-resource-id,…
runefa Mar 21, 2022
6f135aa
Reset to 0.1.0 version, remove unneeded options-list
calvinsID Mar 21, 2022
1977e33
Update min cli core version
calvinsID Mar 21, 2022
c7ed3ca
Fixed style issues. (#30)
runefa Mar 21, 2022
35017f1
Fix linter issues
calvinsID Mar 21, 2022
cf0345e
Use custom-show-command
calvinsID Mar 21, 2022
bddcd61
Removed --ids from revision, secret, registry list.
Mar 21, 2022
9a1354f
Add linter exclusions
calvinsID Mar 21, 2022
a375593
Fix polling on delete containerapp
calvinsID Mar 21, 2022
956875c
Fix error handling
calvinsID Mar 21, 2022
7606bae
Add Container App Service
calvinsID Mar 21, 2022
7ceb9c3
Fix flake linter
calvinsID Mar 21, 2022
9683a85
Fix help text
calvinsID Mar 22, 2022
19b808a
Mark extension as preview
calvinsID Mar 22, 2022
0c2318b
Add python 3.9 and 3.10 as supported
calvinsID Mar 22, 2022
de4b8a8
Remove registries and secrets from az containerapp update, in favor o…
calvinsID Mar 22, 2022
ef0cbc1
Fix YAML not working
calvinsID Mar 22, 2022
943cafd
Move import to inside deserialize function
calvinsID Mar 22, 2022
51bc543
Ingress enable --transport default. Secret list returns empty array. …
Mar 22, 2022
37030ad
Fixed dapr in create.
Mar 23, 2022
60f9e4b
Revert "Ingress enable --transport default. Secret list returns empty…
Mar 23, 2022
feb12a7
Revert "Fixed dapr in create."
Mar 23, 2022
e639c00
Ingress enable --transport default. Secret list returns empty array. …
Mar 22, 2022
0bfdddd
Skeleton code
calvinsID Feb 3, 2022
16afa69
az containerapp env show
calvinsID Feb 3, 2022
2323591
List kube/managed environments
calvinsID Feb 3, 2022
9397d54
Create kube environment, wait doesn't work yet
calvinsID Feb 4, 2022
4fa3771
Update containerapp stubs (check if it is supported now)
calvinsID Feb 4, 2022
0d7ce56
Containerapp env delete, polling not working yet
calvinsID Feb 4, 2022
055907f
Added polling for create and delete
calvinsID Feb 4, 2022
31b2415
Use Microsoft.App RP for show, list, delete command
calvinsID Feb 5, 2022
232512f
Create containerapp env using Microsoft.App RP
calvinsID Feb 6, 2022
baf19b4
Add optional containerapp env create arguments
calvinsID Feb 8, 2022
76f62ba
Remove old kube environment code, naming fixes
calvinsID Feb 8, 2022
12524a7
Containerapp create almost done
calvinsID Feb 11, 2022
99a3d38
Done containerapp create, except for --yaml. Need to test
calvinsID Feb 11, 2022
1c74c2e
Containerapp show, list
calvinsID Feb 11, 2022
3c0c501
Fix helptext
calvinsID Feb 11, 2022
958facf
Containerapp delete
calvinsID Feb 11, 2022
2a230f0
Containerapp update. Needs secrets api to be implemented, and testing
calvinsID Feb 14, 2022
c65b264
Add scale command
calvinsID Feb 14, 2022
2901b61
Various validations, small fixes
calvinsID Feb 15, 2022
02cf535
listSecrets API for updates, autogen log analytics for env
calvinsID Feb 18, 2022
fbd6407
Use space delimiter for secrets and env variables
calvinsID Feb 24, 2022
6513981
Verify sub is registered to Microsoft.ContainerRegistration if creati…
calvinsID Feb 25, 2022
bacf864
Containerapp create --yaml
calvinsID Feb 23, 2022
9777c5f
Fix updating registry to do create or update
calvinsID Feb 23, 2022
71e9c9b
Fix containerapp update command. Add image-name parameter to support …
calvinsID Feb 23, 2022
5e3888a
started update with --yaml. Need to do create or update for when an a…
calvinsID Feb 23, 2022
b419f8d
use space delimiter for startup_command and args, instead of comma de…
calvinsID Feb 24, 2022
84c56b5
Traffic weights
calvinsID Mar 1, 2022
07cae9d
List and show revisions
calvinsID Feb 24, 2022
7df8730
az containerapp revision restart, activate, deactivate
calvinsID Feb 24, 2022
43897cc
Add ability for users to clear args/command in az containerapp update
calvinsID Mar 3, 2022
7a380e3
Various fixes, traffic weights fixes
calvinsID Mar 3, 2022
983af7c
Verify subnet subscription is registered to Microsoft.ContainerServices
calvinsID Mar 4, 2022
328683b
GitHub Actions Update (#17)
runefa Mar 8, 2022
0f582e0
Remove --location since location must be same as managed env
calvinsID Mar 8, 2022
d4272d8
Add options for flag names: --env-vars and --registry-srever
calvinsID Mar 8, 2022
42519dc
Empty string to clear env_vars
calvinsID Mar 8, 2022
8caebc7
Default revisions_mode to single
calvinsID Mar 8, 2022
11e7fe0
Infer acr credentials if it is acr and credentials are not provided
calvinsID Mar 8, 2022
85fd0f5
fix help msg
calvinsID Mar 8, 2022
6bf5a56
if image is hosted on acr, and no registry server is supplied, infer …
calvinsID Mar 9, 2022
25e1250
Added subgroups (Ingress, Registry, Secret) and updated revisions (#18)
runefa Mar 11, 2022
22e428c
More p0 fixes (#20)
calvinsID Mar 11, 2022
e12b19c
Update help text (#21)
anthonychu Mar 14, 2022
abece41
New 1.0.1 version
calvinsID Mar 14, 2022
7d8b9ba
Added identity commands + --assign-identity flag to containerapp crea…
runefa Mar 14, 2022
bc8c58b
Dapr Commands (#23)
runefa Mar 14, 2022
869c11b
Rename --image-name to --container-name
calvinsID Mar 14, 2022
0857b6b
Remove allowInsecure since it was messing with the api parsing
calvinsID Mar 14, 2022
a0acb01
Fix for env var being empty string
calvinsID Mar 14, 2022
0f4f385
Rename to --dapr-instrumentation-key, only infer ACR credentials if -…
calvinsID Mar 14, 2022
144ce57
Remove az containerapp scale
calvinsID Mar 14, 2022
3b01ec6
Fix delete containerapp errors
calvinsID Mar 14, 2022
b671af3
Remove ingress, dapr flags from az containerapp update/revision copy
calvinsID Mar 14, 2022
df1ae0b
Fix revision list -o table
calvinsID Mar 14, 2022
9962e29
Help text fix
calvinsID Mar 14, 2022
ef031f4
Bump extension to 0.1.2
calvinsID Mar 14, 2022
a26df8c
Update managed identities and Dapr help text (#25)
anthonychu Mar 15, 2022
ea45ec8
Env var options + various bug fixes (#26)
runefa Mar 16, 2022
43acd4b
Fixed style issues, various bug fixes (#27)
runefa Mar 18, 2022
a607ed9
Update src/containerapp/azext_containerapp/tests/latest/test_containe…
runefa Mar 18, 2022
9652f3e
Specific Error Types + Bugfixes (Help, remove app-subnet-resource-id,…
runefa Mar 21, 2022
46b5a94
Reset to 0.1.0 version, remove unneeded options-list
calvinsID Mar 21, 2022
a8e75ba
Update min cli core version
calvinsID Mar 21, 2022
c1288b7
Fixed style issues. (#30)
runefa Mar 21, 2022
d4fbdae
Fix linter issues
calvinsID Mar 21, 2022
48f2eb9
Use custom-show-command
calvinsID Mar 21, 2022
f19323f
Removed --ids from revision, secret, registry list.
Mar 21, 2022
0f402d8
Add linter exclusions
calvinsID Mar 21, 2022
8f006f1
Fix polling on delete containerapp
calvinsID Mar 21, 2022
f259b6f
Fix error handling
calvinsID Mar 21, 2022
c96f1e5
Add Container App Service
calvinsID Mar 21, 2022
3b823cf
Fix flake linter
calvinsID Mar 21, 2022
0e5552d
Fix help text
calvinsID Mar 22, 2022
51c540b
Mark extension as preview
calvinsID Mar 22, 2022
ff2ba40
Add python 3.9 and 3.10 as supported
calvinsID Mar 22, 2022
c45cbd0
Remove registries and secrets from az containerapp update, in favor o…
calvinsID Mar 22, 2022
126878c
Fix YAML not working
calvinsID Mar 22, 2022
e64cbef
Move import to inside deserialize function
calvinsID Mar 22, 2022
40d112c
Dapr moved from Template to Configuration
calvinsID Mar 22, 2022
bade2b1
Use aka.ms link for containerapps yaml
calvinsID Mar 22, 2022
0922c68
Updated dapr enable/disable to current spec.
Mar 22, 2022
2badc74
Fixed oversight.
Mar 22, 2022
2bf3686
Remove revisions-mode from containerapp update
calvinsID Mar 23, 2022
eec4e1a
Fixed dapr enable property names. (#47)
runefa Mar 23, 2022
c43d1ca
Fix exceptions with using --yaml in containerapp create/update
calvinsID Mar 23, 2022
a0e7ca1
Rename history msg
calvinsID Mar 24, 2022
5f68333
Include fqdn in containerapp table output
calvinsID Mar 24, 2022
0b6fb6f
Added ingress messages.
Mar 23, 2022
2f07b6e
Revert history msg
calvinsID Mar 24, 2022
1798852
Reduced redundant code between revision copy and containerapp update.
Mar 24, 2022
501756a
Merged containerapp.
Mar 24, 2022
a06d619
Fixed merge issues.
Mar 24, 2022
636d3f7
Fixed merge conflicts, moved helper function
Mar 24, 2022
e92ae3d
Merged main and enabled identity.
Apr 7, 2022
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
49 changes: 48 additions & 1 deletion src/containerapp/azext_containerapp/_help.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,14 @@

"""

helps['containerapp revision copy'] = """
type: command
short-summary: Create a revision based on a previous revision.
examples:
- name: Create a revision based on a previous revision.
text: |
az containerapp revision copy -n MyContainerapp -g MyResourceGroup --cpu 0.75 --memory 1.5Gi
"""

# Environment Commands
helps['containerapp env'] = """
Expand Down Expand Up @@ -256,6 +264,45 @@
az containerapp env dapr-component remove -g MyResourceGroup --dapr-component-name MyDaprComponentName --name MyEnvironment
"""

# Identity Commands
helps['containerapp identity'] = """
type: group
short-summary: Commands to manage managed identities.
"""

helps['containerapp identity assign'] = """
type: command
short-summary: Assign managed identity to a container app.
long-summary: Managed identities can be user-assigned or system-assigned.
examples:
- name: Assign system identity.
text: |
az containerapp identity assign
- name: Assign user identity.
text: |
az containerapp identity assign --identities myAssignedId
- name: Assign system and user identity.
text: |
az containerapp identity assign --identities [system] myAssignedId
"""

helps['containerapp identity remove'] = """
type: command
short-summary: Remove a managed identity from a container app.
examples:
- name: Remove system identity.
text: |
az containerapp identity remove --identities [system]
- name: Remove system and user identity.
text: |
az containerapp identity remove --identities [system] myAssignedId
"""

helps['containerapp identity show'] = """
type: command
short-summary: Show managed identities of a container app.
"""

# Ingress Commands
helps['containerapp ingress'] = """
type: group
Expand Down Expand Up @@ -470,7 +517,7 @@

helps['containerapp dapr enable'] = """
type: command
short-summary: Enable Dapr for a container app.
short-summary: Enable Dapr for a container app. Updates existing values.
examples:
- name: Enable Dapr for a container app.
text: |
Expand Down
7 changes: 7 additions & 0 deletions src/containerapp/azext_containerapp/_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ def load_arguments(self, _):
c.argument('transport', arg_type=get_enum_type(['auto', 'http', 'http2']), help="The transport protocol used for ingress traffic.")

with self.argument_context('containerapp create') as c:
c.argument('assign_identity', nargs='+', help="Space-separated identities. Use '[system]' to refer to the system assigned identity.")
c.argument('traffic_weights', nargs='*', options_list=['--traffic-weight'], help="A list of revision weight(s) for the container app. Space-separated values in 'revision_name=weight' format. For latest revision, use 'latest=weight'")

with self.argument_context('containerapp scale') as c:
Expand Down Expand Up @@ -112,6 +113,12 @@ def load_arguments(self, _):
with self.argument_context('containerapp env show') as c:
c.argument('name', name_type, help='Name of the Container Apps Environment.')

with self.argument_context('containerapp identity') as c:
c.argument('identities', nargs='+', help="Space-separated identities. Use '[system]' to refer to the system assigned identity.")

with self.argument_context('containerapp identity assign') as c:
c.argument('identities', nargs='+', help="Space-separated identities. Use '[system]' to refer to the system assigned identity. Default is '[system]'.")

with self.argument_context('containerapp github-action add') as c:
c.argument('repo_url', help='The GitHub repository to which the workflow file will be added. In the format: https://github.com/<owner>/<repository-name>')
c.argument('token', help='A Personal Access Token with write access to the specified repository. For more information: https://help.github.com/en/github/authenticating-to-github/creating-a-personal-access-token-for-the-command-line')
Expand Down
5 changes: 5 additions & 0 deletions src/containerapp/azext_containerapp/commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@ def load_command_table(self, _):
g.custom_command('set', 'create_or_update_dapr_component')
g.custom_command('remove', 'remove_dapr_component')

with self.command_group('containerapp identity') as g:
g.custom_command('assign', 'assign_managed_identity', supports_no_wait=True, exception_handler=ex_handler_factory())
g.custom_command('remove', 'remove_managed_identity', supports_no_wait=True, exception_handler=ex_handler_factory())
g.custom_show_command('show', 'show_managed_identity')

with self.command_group('containerapp github-action') as g:
g.custom_command('add', 'create_or_update_github_action', exception_handler=ex_handler_factory())
g.custom_show_command('show', 'show_github_action', exception_handler=ex_handler_factory())
Expand Down
Loading