Skip to content
This repository was archived by the owner on May 2, 2022. It is now read-only.

Conversation

@kanika1894
Copy link
Contributor

No description provided.

azureSubscriptionEndpointForSecrets: $(azureSubscription)
azureContainerRegistry: $(containerRegistry)
secretName: $(dockerAuthSecretName)
versionSpec: 1.10.12
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will this remain hard coded ?

dockerFile: $(dockerFile)
imageName: $(imageName)
useDefaultContext: false
buildContext: Application
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can build context always be Application ?

protocol: TCP
name: http
selector:
app: $(appName)' |
Copy link

@hiyadav hiyadav Jan 23, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we also need to consider ingress.yaml for when httpRoutingIsEnabled.
you can asume that parameter AksResource will be of type GenericResource, and hence will have all these information in its properties.

you can extract it this way:
httpRoutingEnabled = {{ inputs.aKSResource.properties.addonProfiles.httpapplicationrouting.enabled }}

- uses: azure/docker-login@v1
with:
login-server: $REGISTRY_URL
username: ${{ assets.REGISTRY_USERNAME }}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

${{ assets.containerRegistryUsername }}

with:
login-server: $REGISTRY_URL
username: ${{ assets.REGISTRY_USERNAME }}
password: ${{ assets.REGISTRY_PASSWORD }}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

${{ assets.containerRegistryPassword}}

build-and-deploy:
env:
REGISTRY_URL: {{#toLower}} {{{inputs.containerRegistry}}} {{/toLower}}.azurecr.io
SERVICE_NAME: {{#sanitizeString}} {{{ inputs.AKSresource.name 50}}} {{/sanitizeString}}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

inputs.aksCluster

use this where we need to access the cluster resource

namespacePresent=`kubectl get namespace | grep $NAMESPACE | wc -l`
if [ $namespacePresent -eq 0 ]
then
echo `kubectl create namespace $NAMESPACE`
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we assume that the namespace is created after running this command or do we need to wait/check again for confirmation ?


- uses: azure/k8s-set-context@v1
with:
kubeconfig: ${{ secrets.KUBE_CONFIG }}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we also need to add logout in the end of workflow ?

azureSubscription: '{{{ assets.serviceConnectionId }}}'

# Kubernetes Service name
serviceName: '{{ #sanitizeString }} {{{ inputs.AKSresource.name }}} {{ /sanitizeString }}'
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use inputs.aksCluster


- uses: azure/k8s-set-context@v1
with:
kubeconfig: ${{ secrets.KUBE_CONFIG }}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

assets.aksKubeConfig

@kanika1894 kanika1894 closed this Jun 11, 2020
@kanika1894 kanika1894 reopened this Jun 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants