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

Commit

Permalink
Merge pull request #10 from maxstreifeneder/master
Browse files Browse the repository at this point in the history
New Release - 1.4.0
  • Loading branch information
Marius Obert authored Jan 21, 2020
2 parents daa9687 + 50926d0 commit 7d9608b
Show file tree
Hide file tree
Showing 5 changed files with 67 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
name: Publish Release on GitHub
command: |
VERSION=$(cat ~/repo/package.json | grep version | head -1 | awk -F: '{ print $2 }' | sed 's/[",]//g' | tr -d '[[:space:]]' )
ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete ${VERSION} mta_archives/city-explorer-demo-app_${VERSION}.mtar
ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete ${VERSION} mta_archives/city-explorer-demo-app.mtar
workflows:
version: 2
Expand Down
53 changes: 53 additions & 0 deletions azure-pipelines.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Starter pipeline
# Start with a minimal pipeline that you can customize to build and deploy your code.
# Add steps that build, run tests, deploy, and more:
# https://aka.ms/yaml


name: cap-osba-app
resources:
containers:
- container: mta
image: 'ppiper/mta-archive-builder:latest'
options: --user 0:0
- container: cfcli
image: 'ppiper/cf-cli'
options: --user 0:0 --privileged


trigger:
- master

stages:
- stage: Build
displayName: Build MTA for SAP Cloud Platform
jobs:
- job: build
pool:
vmImage: 'ubuntu-latest'
container: mta
steps:
- bash: npm install
displayName: npm install
- bash: npm run build:mta
displayName: Build MTA
- bash: npx cds deploy
displayName: Deploy CDS Artefacts
- bash: npm test
displayName: Test CAP application
- publish: $(System.DefaultWorkingDirectory)/mta_archives/.
artifact: WebApp

- stage: Deploy
displayName: Deployment to SAP Cloud Platform
jobs:
- job: deploy
pool:
vmImage: 'ubuntu-latest'
container: cfcli
steps:
- download: current
artifact: WebApp
- bash: |
cf login -u "$(CF-USER)" -p "$(CF-PASSWORD)" -a "$(CF-API)" -o "$(CF-ORG)" -s "$(CF-SPACE)"
cf deploy $(Pipeline.Workspace)/WebApp/city-explorer-demo-app.mtar -f
12 changes: 9 additions & 3 deletions mta.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
_schema-version: 2.0.0
_schema-version: 3.3.0
ID: city-explorer-demo-app
version: 1.3.6
version: 1.4.0
parameters:
enable-parallel-deployments: true
modules:
- name: city-cap-router
type: approuter.nodejs
path: app
deployed-after:
- city-image-uploader
- city-cap-srv
parameters:
disk-quota: 256M
memory: 256M
Expand Down Expand Up @@ -62,12 +67,13 @@ resources:
hdi-container-name: ${service-name}
parameters:
service: hanatrial
service-alternatives: ["hana"]
- name: azure-blob-storage
type: org.cloudfoundry.managed-service
parameters:
service: azure-storage-blob-storage-account-and-container
service-plan: all-in-one
config:
location: "northeurope"
resourceGroup: "SAPTechEd"
resourceGroup: "SAPCloudPlatform"
accessTier: "Cool"
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "city-explorer-demo-app",
"description": "Demo application for TechEd 2019",
"version": "1.3.6",
"description": "Demo application for SAP Cloud Application Programming Model and Azure Services",
"version": "1.4.0",
"engines": {
"node": "^8.9"
},
Expand All @@ -24,7 +24,7 @@
"test": "mocha",
"lint": "eslint .",
"deploy:cds": "cds deploy",
"build:mta": "cds build/all && cds deploy && mbt build -p=cf",
"build:mta": "cds build/all && cds deploy && mbt build -p=cf --mtar=city-explorer-demo-app.mtar",
"deploy:cf": "npm run build:mta && cf deploy mta_archives/${npm_package_name}_${npm_package_version}.mtar"
}
}

0 comments on commit 7d9608b

Please sign in to comment.