Skip to content
This repository has been archived by the owner on Jan 26, 2021. It is now read-only.

Commit

Permalink
Merge pull request #3 from Azure/master
Browse files Browse the repository at this point in the history
Merge from master
  • Loading branch information
mathieu-benoit authored Nov 6, 2018
2 parents a650743 + f34da85 commit 3081a4e
Show file tree
Hide file tree
Showing 5 changed files with 177 additions and 3 deletions.
16 changes: 13 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ We loved the story and the imagery in it and thought the characters from the Ill
1. [Where is Phippy?](#but-where-is-phippy)
1. [Watch in real time](#watch-in-real-time)
1. [Try scaling your apps](#try-scaling-your-apps)
1. [Leverage Azure DevOps](#leverage-azure-devops)
1. [Issues and Contributions](#issues)

---
Expand Down Expand Up @@ -156,8 +157,6 @@ The final service is a basic Node.js application represented by the Node.js-deco

You can cd into this service's folder and deploy it using `draft up` as you did with the others. But for fun, do this in a window that's side-by-side with the parrot dashboard. This way you can see services appear as you `draft up` and vanish as you `draft delete`.



### Try Scaling your Apps

Scale your nodebrady by running this:
Expand All @@ -168,6 +167,17 @@ kubectl scale deployment/nodebrady-nodebrady --replicas 3 --namespace phippyandf

Watch as more brady ninjas come to life!

## Leverage Azure DevOps

You could also leverage [Azure DevOps](https://docs.microsoft.com/azure/devops) to implement a [CI/CD pipeline](https://docs.microsoft.com/azure/devops/pipelines) for each app. For that you could [create one Azure build pipeline](https://docs.microsoft.com/azure/devops/pipelines/get-started-yaml#get-your-first-build) per app by using its associated YAML definition:

- [parrot/azure-pipelines.yml](parrot/azure-pipelines.yml)
- [captainkube/azure-pipelines.yml](captainkube/azure-pipelines.yml)
- [phippy/azure-pipelines.yml](phippy/azure-pipelines.yml)
- [nodebrady/azure-pipelines.yml](nodebrady/azure-pipelines.yml)

*Coming soon: more to come, a blog article is coming explaining how to setup your Azure release pipeline. Stay tuned!*

## Issues?

Phippy and Friends is open-source, and we'd love your contributions. Submit issues, then work those issues and send us a pull request. Customize the parrot dashboard with a theme, put the characters on a boat, launch them into space. We'd love to see what other characters you'll add to the dashboard!
Expand All @@ -188,6 +198,6 @@ helm delete --purge parrot
## Credits
Some awesome people worked on the Phippy and Friends demo. [Stella Lin]() brought the idea to [Brady Gaster](), who then got a **ton** of help from [Ralph Squillace]() and [Ahmed Sabbour]() to bring it to life. As mentioned earlier, Phippy and Friends was originally inspired by a blog post written by [Matt](https://twitter.com/technosophos) [Butcher](http://technosophos.com/).
Some awesome people worked on the Phippy and Friends demo. [Stella Lin]() brought the idea to [Brady Gaster](), who then got a **ton** of help from [Ralph Squillace]() and [Ahmed Sabbour](http://twitter.com/sabbour) to bring it to life and [Mathieu Benoit](http://github.com/mathieu-benoit) for his Azure DevOps build pipeline. As mentioned earlier, Phippy and Friends was originally inspired by a blog post written by [Matt](https://twitter.com/technosophos) [Butcher](http://technosophos.com/).
You can help too, by submitting a pull request and adding your own contributions. When you do, make sure to add your contributions' summary to this section, too!
41 changes: 41 additions & 0 deletions captainkube/azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
pool:
vmImage: 'Ubuntu 16.04'


variables:
registryServerName: '$(registryName).azurecr.io'
projectName: 'captainkube'
imageName: '$(projectName)'
# define 4 more variables registryAzureSubscriptionServiceEndpoint, registryName, registryLogin and registryPassword in the build pipeline in UI


steps:
- bash: docker build -f $(system.defaultWorkingDirectory)/$(projectName)/Dockerfile -t $(registryServerName)/$(imageName):$(build.buildId) -t $(registryServerName)/$(imageName):latest $(system.defaultWorkingDirectory)/$(projectName)
displayName: 'docker build'

- bash: docker login $(registryServerName) -u $(registryLogin) -p $(registryPassword)
displayName: 'docker login'

- bash: |
docker push $(registryServerName)/$(imageName):$(build.buildId)
docker push $(registryServerName)/$(imageName):latest
displayName: 'docker push'
condition: and(succeeded(), eq(variables['build.sourceBranch'], 'refs/heads/master'))

- task: HelmInstaller@0
displayName: 'Install Helm 2.11.0'
inputs:
helmVersion: 2.11.0

- bash: helm init --client-only --wait
displayName: 'helm init'

- bash: helm package --version $(build.buildId) --destination $(build.artifactStagingDirectory) $(system.defaultWorkingDirectory)/$(projectName)/charts/$(projectName)
displayName: 'helm package'

- task: AzureCLI@1
displayName: 'az acr helm push'
inputs:
azureSubscription: '$(registryAzureSubscriptionServiceEndpoint)'
scriptLocation: inlineScript
inlineScript: 'az acr helm push -n $(registryName) $(build.artifactStagingDirectory)/$(projectName)-$(build.buildId).tgz'
41 changes: 41 additions & 0 deletions nodebrady/azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
pool:
vmImage: 'Ubuntu 16.04'


variables:
registryServerName: '$(registryName).azurecr.io'
projectName: 'nodebrady'
imageName: '$(projectName)'
# define 4 more variables registryAzureSubscriptionServiceEndpoint, registryName, registryLogin and registryPassword in the build pipeline in UI


steps:
- bash: docker build -f $(system.defaultWorkingDirectory)/$(projectName)/Dockerfile -t $(registryServerName)/$(imageName):$(build.buildId) -t $(registryServerName)/$(imageName):latest $(system.defaultWorkingDirectory)/$(projectName)
displayName: 'docker build'

- bash: docker login $(registryServerName) -u $(registryLogin) -p $(registryPassword)
displayName: 'docker login'

- bash: |
docker push $(registryServerName)/$(imageName):$(build.buildId)
docker push $(registryServerName)/$(imageName):latest
displayName: 'docker push'
condition: and(succeeded(), eq(variables['build.sourceBranch'], 'refs/heads/master'))

- task: HelmInstaller@0
displayName: 'Install Helm 2.11.0'
inputs:
helmVersion: 2.11.0

- bash: helm init --client-only --wait
displayName: 'helm init'

- bash: helm package --version $(build.buildId) --destination $(build.artifactStagingDirectory) $(system.defaultWorkingDirectory)/$(projectName)/charts/$(projectName)
displayName: 'helm package'

- task: AzureCLI@1
displayName: 'az acr helm push'
inputs:
azureSubscription: '$(registryAzureSubscriptionServiceEndpoint)'
scriptLocation: inlineScript
inlineScript: 'az acr helm push -n $(registryName) $(build.artifactStagingDirectory)/$(projectName)-$(build.buildId).tgz'
41 changes: 41 additions & 0 deletions parrot/azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
pool:
vmImage: 'Ubuntu 16.04'


variables:
registryServerName: '$(registryName).azurecr.io'
projectName: 'parrot'
imageName: '$(projectName)'
# define 4 more variables registryAzureSubscriptionServiceEndpoint, registryName, registryLogin and registryPassword in the build pipeline in UI


steps:
- bash: docker build -f $(system.defaultWorkingDirectory)/$(projectName)/Dockerfile -t $(registryServerName)/$(imageName):$(build.buildId) -t $(registryServerName)/$(imageName):latest $(system.defaultWorkingDirectory)/$(projectName)
displayName: 'docker build'

- bash: docker login $(registryServerName) -u $(registryLogin) -p $(registryPassword)
displayName: 'docker login'

- bash: |
docker push $(registryServerName)/$(imageName):$(build.buildId)
docker push $(registryServerName)/$(imageName):latest
displayName: 'docker push'
condition: and(succeeded(), eq(variables['build.sourceBranch'], 'refs/heads/master'))

- task: HelmInstaller@0
displayName: 'Install Helm 2.11.0'
inputs:
helmVersion: 2.11.0

- bash: helm init --client-only --wait
displayName: 'helm init'

- bash: helm package --version $(build.buildId) --destination $(build.artifactStagingDirectory) $(system.defaultWorkingDirectory)/$(projectName)/charts/$(projectName)
displayName: 'helm package'

- task: AzureCLI@1
displayName: 'az acr helm push'
inputs:
azureSubscription: '$(registryAzureSubscriptionServiceEndpoint)'
scriptLocation: inlineScript
inlineScript: 'az acr helm push -n $(registryName) $(build.artifactStagingDirectory)/$(projectName)-$(build.buildId).tgz'
41 changes: 41 additions & 0 deletions phippy/azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
pool:
vmImage: 'Ubuntu 16.04'


variables:
registryServerName: '$(registryName).azurecr.io'
projectName: 'phippy'
imageName: '$(projectName)'
# define 4 more variables registryAzureSubscriptionServiceEndpoint, registryName, registryLogin and registryPassword in the build pipeline in UI


steps:
- bash: docker build -f $(system.defaultWorkingDirectory)/$(projectName)/Dockerfile -t $(registryServerName)/$(imageName):$(build.buildId) -t $(registryServerName)/$(imageName):latest $(system.defaultWorkingDirectory)/$(projectName)
displayName: 'docker build'

- bash: docker login $(registryServerName) -u $(registryLogin) -p $(registryPassword)
displayName: 'docker login'

- bash: |
docker push $(registryServerName)/$(imageName):$(build.buildId)
docker push $(registryServerName)/$(imageName):latest
displayName: 'docker push'
condition: and(succeeded(), eq(variables['build.sourceBranch'], 'refs/heads/master'))

- task: HelmInstaller@0
displayName: 'Install Helm 2.11.0'
inputs:
helmVersion: 2.11.0

- bash: helm init --client-only --wait
displayName: 'helm init'

- bash: helm package --version $(build.buildId) --destination $(build.artifactStagingDirectory) $(system.defaultWorkingDirectory)/$(projectName)/charts/$(projectName)
displayName: 'helm package'

- task: AzureCLI@1
displayName: 'az acr helm push'
inputs:
azureSubscription: '$(registryAzureSubscriptionServiceEndpoint)'
scriptLocation: inlineScript
inlineScript: 'az acr helm push -n $(registryName) $(build.artifactStagingDirectory)/$(projectName)-$(build.buildId).tgz'

0 comments on commit 3081a4e

Please sign in to comment.