remove unused files, updated readme [#153640396]
This commit is contained in:
Родитель
bb4e1dcd23
Коммит
9e81ff33b4
|
@ -1,2 +1,3 @@
|
|||
If you have not previously done so, please fill out and
|
||||
submit the [Contributor License Agreement](https://cla.pivotal.io/sign/pivotal).
|
||||
# Contributing
|
||||
|
||||
If you have not previously done so, please fill out and submit the [Contributor License Agreement](https://cla.pivotal.io/sign/pivotal).
|
||||
|
|
42
README.md
42
README.md
|
@ -1,38 +1,28 @@
|
|||
# steeltoe-ci
|
||||
# Steeltoe Continuous Integration
|
||||
|
||||
Config files for Steeltoe CI
|
||||
## Workflow Overview
|
||||
|
||||
## Changing pipelines
|
||||
Pushing changes to any Steeltoe repository on GitHub will trigger CI builds on both AppVeyor (Windows) and Travis CI (Linux and OSX). All NuGet packages are built in AppVeyor. Travis CI is used for cross-platform compatibility testing only.
|
||||
|
||||
Change the files, then:
|
||||
## Work out of (or PR into) dev branch, packages deploy to myget/dev
|
||||
|
||||
```bash
|
||||
./update.sh
|
||||
```
|
||||
Successful AppVeyor builds from the dev branch publish pre-release NuGet packages to the [Steeltoe Dev feed](https://www.myget.org/F/steeltoedev/api/v3/index.json) with a suffix of -dev-{build number}
|
||||
|
||||
## Creating docker images
|
||||
## Stable code merged to master branch, packages deploy to myget/master
|
||||
|
||||
### Base image, `cf-cli`
|
||||
```bash
|
||||
(cd dockerfiles/cf-cli && docker build -t dgodd/cf-cli . && docker push dgodd/cf-cli)
|
||||
```
|
||||
Once deemed stable, code is merged into the master branch. Successful AppVeyor builds from the master branch will publish pre-release NuGet packages to the [Steeltoe Master feed](https://www.myget.org/F/steeltoedev/api/v3/index.json) with a suffix of -master-{build number}
|
||||
|
||||
### Base image, `cf-space-resource`
|
||||
```bash
|
||||
(cd dockerfiles/cf-space-resource && docker build -t dgodd/cf-space-resource . && docker push dgodd/cf-space-resource)
|
||||
```
|
||||
## Complete Steeltoe Releases - Publish to myget/staging then to nuget.org
|
||||
|
||||
### For pcfdev windows machine
|
||||
When its time for a full release of Steeltoe, the [Steeltoe Universe PowerShell script](/scripts/steeltoe_universe.ps1) will be run on AppVeyor. The script will clone all repositories from GitHub into a temporary local workspace, update all Steeltoe versions in .props files to the version passed in as a parameter, build packages, (optionally) run unit tests, and publish to the [Steeltoe Staging feed](https://www.myget.org/F/steeltoestaging/api/v3/index.json).
|
||||
Once the team is confident in the release, AppVeyor is used to push all packages to nuget.org via Environment deployments (click Deploy from the AppVeyor build)
|
||||
|
||||
Install using (after changing MACHINE_IP)
|
||||
Universe Script Options:
|
||||
|
||||
```
|
||||
wget misty-sisters.surge.sh/garden.zip
|
||||
```
|
||||
- `-BuildDebug` - using this switch causes the script to pull the default branch instead of master
|
||||
- `$env:SteeltoeRepositoryList` - a space separated list of repositories; cloned and built in order specified. The default/complete list is maintained inside the Universe script
|
||||
- `$env:RunUnitTests`: false (default)
|
||||
|
||||
Install the https certificate on linux and windows since it is self signed
|
||||
## Patch releases
|
||||
|
||||
### Useful commands
|
||||
|
||||
* To find all of the apps on a CF instance (after logging in as admin):
|
||||
`cf curl '/v2/apps?inline-relations-depth=2' | jq -r '.resources[].entity|{org:.space.entity.organization.entity.name, space:.space.entity.name, name:.name}'`
|
||||
When patching is required: Create a branch named update{MajorMinor}x (eg: update20x for patches on the 2.0 release) if it does not already exist. Note: numbering of the branch does not affect build/deploy processes, the scripts only look for a starting value of ‘update’ in the branch name. Package versioning is controlled in appveyor.yml. Successful AppVeyor builds from update branches publish nuget packages to the Steeltoe Staging feed on myget.org with with no pre-release suffix unless the branch name includes one. For example: a branch named “update20x-rc1” will produce pre-release packages with the suffix -rc1, while “update20x” will produce packages with no suffix.
|
||||
|
|
|
@ -1,15 +0,0 @@
|
|||
FROM alpine:latest
|
||||
|
||||
RUN apk update \
|
||||
&& apk add ca-certificates pwgen bash curl jq vim \
|
||||
&& update-ca-certificates \
|
||||
&& rm -r /var/cache/
|
||||
|
||||
RUN curl -L 'https://cli.run.pivotal.io/stable?release=linux64-binary&source=github' | tar -zx -C /usr/local/bin/
|
||||
|
||||
# Use Concourse Credentials Filter
|
||||
# RUN curl -L 'https://github.com/pivotal-cf-experimental/concourse-filter/releases/download/v0.0.1/concourse-filter' -o /usr/local/bin/concourse-filter && chmod +x /usr/local/bin/concourse-filter
|
||||
# RUN mkdir -p /etc/profile.d/
|
||||
# COPY filter.sh /etc/profile.d/
|
||||
# RUN chmod 755 /etc/profile.d/filter.sh
|
||||
# ENV BASH_ENV /etc/profile.d/filter.sh
|
|
@ -1,5 +0,0 @@
|
|||
#! /usr/bin/env bash
|
||||
|
||||
export CREDENTIAL_FILTER_WHITELIST="HOME,TMPDIR,PWD,LANGUAGE,TERM,USER,LANG,SHLVL,OLDPWD"
|
||||
|
||||
exec &> >(concourse-filter)
|
|
@ -1,6 +0,0 @@
|
|||
FROM steeltoeoss/cf-cli:latest
|
||||
|
||||
ENV TMPDIR /tmp
|
||||
RUN mkdir -p /opt/resource/
|
||||
COPY check in out /opt/resource/
|
||||
|
|
@ -1,16 +0,0 @@
|
|||
#!/usr/bin/env sh
|
||||
exec 3>&1 # make stdout available as fd 3 for the result
|
||||
exec 1>&2 # redirect all output to stderr for logging
|
||||
set -eu +x -o pipefail
|
||||
|
||||
payload=$TMPDIR/cf-space-resource-request
|
||||
cat > $payload <&0
|
||||
|
||||
TARGET=`jq -r '.source.target' < $payload`
|
||||
USERNAME=`jq -r '.source.username' < $payload`
|
||||
PASSWORD=`jq -r '.source.password' < $payload`
|
||||
ORGANIZATION=`jq -r '.source.organization' < $payload`
|
||||
|
||||
cf login -a $TARGET -u $USERNAME -p $PASSWORD --skip-ssl-validation -o dev -s dev
|
||||
|
||||
cf curl "/v2/organizations?q=name%3A${ORGANIZATION}&inline-relations-depth=1" | jq -r '.resources[0].entity.spaces|sort_by(.metadata.created_at)|reverse|map(.entity|{ref: .name})' >&3
|
|
@ -1,47 +0,0 @@
|
|||
#!/usr/bin/env sh
|
||||
exec 3>&1 # make stdout available as fd 3 for the result
|
||||
exec 1>&2 # redirect all output to stderr for logging
|
||||
set -eu +x -o pipefail
|
||||
|
||||
payload=$TMPDIR/cf-space-resource-request
|
||||
cat > $payload <&0
|
||||
|
||||
DESTINATION=$1
|
||||
TARGET=`jq -r '.source.target' < $payload`
|
||||
USERNAME=`jq -r '.source.username' < $payload`
|
||||
PASSWORD=`jq -r '.source.password' < $payload`
|
||||
ORGANIZATION=`jq -r '.source.organization' < $payload`
|
||||
TYPE=`jq -r '.source.TYPE' < $payload`
|
||||
SPACE=`jq -r '.version.ref' < $payload`
|
||||
echo "TYPE: $TYPE"
|
||||
|
||||
echo "#!/usr/bin/env sh" > $DESTINATION/login
|
||||
echo "set +x" >> $DESTINATION/login
|
||||
echo "echo Logging in to $SPACE on $ORGANIZATION on $TARGET" >> $DESTINATION/login
|
||||
echo "cf login -a $TARGET -u $USERNAME -p $PASSWORD --skip-ssl-validation -o $ORGANIZATION -s $SPACE" >> $DESTINATION/login
|
||||
chmod 755 $DESTINATION/login
|
||||
source $DESTINATION/login
|
||||
|
||||
echo $SPACE > $DESTINATION/name
|
||||
echo "export SPACE=$SPACE" > $DESTINATION/variables
|
||||
|
||||
if [ $TYPE == "LINUX" ]; then
|
||||
echo "export MANIFEST_YAML=manifest.yml" >> $DESTINATION/variables
|
||||
echo "export FRAMEWORK=netcoreapp2.0" >> $DESTINATION/variables
|
||||
echo "export RUNTIME=ubuntu.14.04-x64" >> $DESTINATION/variables
|
||||
echo "export STACK=cflinuxfs2" >> $DESTINATION/variables
|
||||
fi
|
||||
if [ $TYPE == "WINDOWS" ]; then
|
||||
echo "export MANIFEST_YAML=manifest-windows.yml" >> $DESTINATION/variables
|
||||
echo "export FRAMEWORK=netcoreapp2.0" >> $DESTINATION/variables
|
||||
echo "export RUNTIME=win7-x64" >> $DESTINATION/variables
|
||||
echo "export STACK=windows2012R2" >> $DESTINATION/variables
|
||||
fi
|
||||
if [ $TYPE == "NET451" ]; then
|
||||
echo "export MANIFEST_YAML=manifest-windows.yml" >> $DESTINATION/variables
|
||||
echo "export FRAMEWORK=net451" >> $DESTINATION/variables
|
||||
echo "export RUNTIME=win7-x64" >> $DESTINATION/variables
|
||||
echo "export STACK=windows2012R2" >> $DESTINATION/variables
|
||||
fi
|
||||
|
||||
echo "{\"version\": {\"ref\": \"$SPACE\"}}" >&3
|
|
@ -1,19 +0,0 @@
|
|||
#!/usr/bin/env sh
|
||||
exec 3>&1 # make stdout available as fd 3 for the result
|
||||
exec 1>&2 # redirect all output to stderr for logging
|
||||
set -eu +x -o pipefail
|
||||
|
||||
payload=$TMPDIR/cf-space-resource-request
|
||||
cat > $payload <&0
|
||||
|
||||
TARGET=`jq -r '.source.target' < $payload`
|
||||
USERNAME=`jq -r '.source.username' < $payload`
|
||||
PASSWORD=`jq -r '.source.password' < $payload`
|
||||
ORGANIZATION=`jq -r '.source.organization' < $payload`
|
||||
|
||||
cf login -a $TARGET -u $USERNAME -p $PASSWORD --skip-ssl-validation -o $ORGANIZATION
|
||||
|
||||
SPACE=$(pwgen -1 | awk '{print tolower($0)}')
|
||||
cf create-space ${SPACE} -o $ORGANIZATION
|
||||
|
||||
echo "{\"version\": {\"ref\":\"$SPACE\"},\"metadata\":[]}" >&3
|
|
@ -1,18 +0,0 @@
|
|||
FROM microsoft/dotnet:1.1.4-sdk-jessie
|
||||
|
||||
RUN curl -L 'https://cli.run.pivotal.io/stable?release=linux64-binary&source=github' | tar -zx -C /usr/local/bin/
|
||||
|
||||
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF \
|
||||
&& echo "deb http://download.mono-project.com/repo/debian wheezy-libjpeg62-compat main" | tee -a /etc/apt/sources.list.d/mono-xamarin.list \
|
||||
&& echo "deb http://download.mono-project.com/repo/debian wheezy/snapshots/4.4.2.11 main" | tee -a /etc/apt/sources.list.d/mono-xamarin.list \
|
||||
&& apt-get update \
|
||||
&& curl -sL https://deb.nodesource.com/setup_6.x | bash - \
|
||||
&& (apt-get install --fix-missing -y mono-devel vim nodejs || apt-get install --fix-missing -y mono-devel vim nodejs) \
|
||||
&& npm install -g bower \
|
||||
&& npm install -g gulp \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Fix https://github.com/npm/npm/issues/9863
|
||||
RUN cd $(npm root -g)/npm \
|
||||
&& npm install fs-extra \
|
||||
&& sed -i -e s/graceful-fs/fs-extra/ -e s/fs\.rename/fs.move/ ./lib/utils/rename.js
|
|
@ -1,18 +0,0 @@
|
|||
FROM microsoft/dotnet:2.0.0-sdk-stretch
|
||||
|
||||
RUN curl -L 'https://cli.run.pivotal.io/stable?release=linux64-binary&source=github' | tar -zx -C /usr/local/bin/
|
||||
|
||||
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF \
|
||||
&& echo "deb http://download.mono-project.com/repo/debian wheezy-libjpeg62-compat main" | tee -a /etc/apt/sources.list.d/mono-xamarin.list \
|
||||
&& echo "deb http://download.mono-project.com/repo/debian wheezy/snapshots/4.4.2.11 main" | tee -a /etc/apt/sources.list.d/mono-xamarin.list \
|
||||
&& apt-get update \
|
||||
&& curl -sL https://deb.nodesource.com/setup_6.x | bash - \
|
||||
&& (apt-get install --fix-missing -y mono-devel vim nodejs || apt-get install --fix-missing -y mono-devel vim nodejs) \
|
||||
&& npm install -g bower \
|
||||
&& npm install -g gulp \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Fix https://github.com/npm/npm/issues/9863
|
||||
RUN cd $(npm root -g)/npm \
|
||||
&& npm install fs-extra \
|
||||
&& sed -i -e s/graceful-fs/fs-extra/ -e s/fs\.rename/fs.move/ ./lib/utils/rename.js
|
|
@ -1,4 +0,0 @@
|
|||
FROM ruby:latest
|
||||
|
||||
RUN curl -L 'https://cli.run.pivotal.io/stable?release=linux64-binary&source=github' | tar -zx -C /usr/local/bin/
|
||||
RUN gem install mechanize cf-uaac
|
Разница между файлами не показана из-за своего большого размера
Загрузить разницу
|
@ -1,20 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -eux
|
||||
|
||||
./cf-space/login
|
||||
export SPACE=`cat cf-space/name`
|
||||
export DATA=`cf curl "/v2/spaces?q=name%3A${SPACE}&inline-relations-depth=2" | jq '.resources[].entity|{apps:.apps|map(.entity.name), services:.service_instances|map(.entity.name)}'`
|
||||
|
||||
for app in `echo $DATA | jq -r '.apps[]'`; do
|
||||
cf delete -f $app
|
||||
done
|
||||
|
||||
for service in `echo $DATA | jq -r '.services[]'`; do
|
||||
cf delete-service -f $service
|
||||
done
|
||||
|
||||
for service in `echo $DATA | jq -r '.services[]'`; do
|
||||
cf purge-service-instance -f $service | true
|
||||
done
|
||||
|
||||
cf delete-space -f $SPACE
|
|
@ -1,15 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -ex
|
||||
|
||||
export URL=`cat cf-push/url`
|
||||
|
||||
if [ ! -z "$PRECOND" ]; then
|
||||
eval $PRECOND
|
||||
fi
|
||||
|
||||
if [[ `curl -k https://${URL}${URL_PATH}` == *"${TEXT}"* ]]; then
|
||||
echo "Found $TEXT"
|
||||
else
|
||||
sleep 10
|
||||
exit 1
|
||||
fi
|
|
@ -1,24 +0,0 @@
|
|||
#!/usr/bin/env ruby
|
||||
require 'rubygems'
|
||||
require 'net/http'
|
||||
require 'json'
|
||||
require 'uri'
|
||||
|
||||
space = ENV['SPACE'] or raise 'Please specify space'
|
||||
uri = URI("http://fortuneui-#{space}.cfapps.pez.pivotal.io/random")
|
||||
puts "Check #{uri}"
|
||||
# => {"id"=>1021, "text"=>"The greatest risk is not taking one."}
|
||||
res = Net::HTTP.get_response(uri)
|
||||
raise "Received #{res.code}" unless res.is_a?(Net::HTTPSuccess)
|
||||
json = JSON.parse(res.body)
|
||||
|
||||
json['id'].to_i > 0 or raise "JSON did not return an id"
|
||||
json['text'].to_s.length > 0 or raise "JSON did not return text"
|
||||
|
||||
system('./cf-space/login') if File.exists?('./cf-space/login')
|
||||
system('cf', 'stop', 'fortuneService')
|
||||
|
||||
res = Net::HTTP.get_response(uri)
|
||||
raise "Expected 500 after stopping service" if res.is_a?(Net::HTTPSuccess)
|
||||
|
||||
puts "Success"
|
|
@ -1,76 +0,0 @@
|
|||
#!/usr/bin/env ruby
|
||||
require 'rubygems'
|
||||
require 'mechanize'
|
||||
require 'json'
|
||||
|
||||
space = ENV['SPACE'] or raise 'Please specify space'
|
||||
agent = Mechanize.new
|
||||
agent.verify_mode = 0
|
||||
|
||||
puts "Start"
|
||||
page = agent.get("http://musicui-#{space}.cfapps.pez.pivotal.io/")
|
||||
|
||||
puts "View Classical Genre"
|
||||
page = page.link_with(href: /Genre=Classical/).click
|
||||
page.search('div.genre h3:first').text.strip == "Classical Albums" or raise "Expected H3 of Classical Albums"
|
||||
|
||||
puts "View Single Album"
|
||||
page = page.link_with(text: /Purcell: The Fairy Queen/).click
|
||||
page.search('h2:first').text.strip == "Purcell: The Fairy Queen" or raise "Expected H2 of Purcell: The Fairy Queen"
|
||||
|
||||
puts "Add to Cart"
|
||||
page = page.link_with(text: /Add to cart/).click
|
||||
|
||||
puts "Attempt to Checkout"
|
||||
page.search('h3:first').text.strip == "Review your cart:" or raise "Expected H3 of Review your cart:"
|
||||
page = page.link_with(text: /Checkout >>/).click
|
||||
page.search('h4:first').text.strip =~ /Use a local account to log in/ or raise "Expected H4 of Use a local account to log in"
|
||||
|
||||
puts "Register"
|
||||
page = page.link_with(text: /Register as a new user?/).click
|
||||
page = page.form_with(action: '/Account/Register') do |f|
|
||||
f.Email = 'user@example.com'
|
||||
f.Password = 'Pass1!'
|
||||
f.ConfirmPassword = 'Pass1!'
|
||||
end.submit
|
||||
page.search('h1:first').text.strip =~ /Demo link display page/ or raise "Expected H1 of Demo link display page"
|
||||
|
||||
puts "Login"
|
||||
page = page.link_with(text: /Log in/).click
|
||||
page = page.form_with(action: '/Account/Login') do |f|
|
||||
f.Email = 'user@example.com'
|
||||
f.Password = 'Pass1!'
|
||||
end.submit
|
||||
page.search('.navbar a[title=Manage]').text.strip == 'Hello user@example.com!' or raise 'Login Failed'
|
||||
|
||||
puts "Checkout"
|
||||
page = page.link_with(href: '/ShoppingCart').click
|
||||
page = page.link_with(text: /Checkout >>/).click
|
||||
page = page.form_with(action: '/Checkout/AddressAndPayment') do |f|
|
||||
f.FirstName = 'Fred'
|
||||
f.LastName = 'Example'
|
||||
f.Address = '625 6th Ave'
|
||||
f.City = 'New York'
|
||||
f.State = 'NY'
|
||||
f.PostalCode = '10011'
|
||||
f.Country = 'USA'
|
||||
f.Phone = '(666) 792-5770'
|
||||
f.Email = 'user@example.com'
|
||||
f.PromoCode = 'FREE'
|
||||
end.submit
|
||||
page.search('h2:first').text.strip =~ /Checkout Complete/ or raise "Expected H4 of Checkout Complete"
|
||||
|
||||
puts "Login as admin"
|
||||
page = page.form_with(action: "/Account/LogOff").submit
|
||||
page = page.link_with(text: /Log in/).click
|
||||
page = page.form_with(action: '/Account/Login') do |f|
|
||||
f.Email = 'Administrator@test.com'
|
||||
f.Password = 'YouShouldChangeThisPassword1!'
|
||||
end.submit
|
||||
page.search('.navbar a[title=Manage]').text.strip == 'Hello Administrator@test.com!' or raise 'Admin Login Failed'
|
||||
|
||||
puts "View StoreManager"
|
||||
page = page.link_with(text: /admin/).click
|
||||
page.link_with(text: /Create New/).text.strip =~ /Create New/ or raise "Expected link of Create New"
|
||||
|
||||
puts "Test Passed"
|
|
@ -1,27 +0,0 @@
|
|||
#!/usr/bin/env ruby
|
||||
require 'rubygems'
|
||||
require 'mechanize'
|
||||
require 'json'
|
||||
|
||||
space = ENV['SPACE'] or raise 'Please specify space'
|
||||
agent = Mechanize.new
|
||||
agent.verify_mode = 0
|
||||
|
||||
page = agent.get("http://single-signon-#{space}.cfapps.pez.pivotal.io/Home/About")
|
||||
page.uri.to_s.match('http[s]?://myuaa-.*.cfapps.pez.pivotal.io/login') or raise 'Should force Auth'
|
||||
page = page.form_with(action: '/login.do') do |f|
|
||||
f.username = "user#{space}"
|
||||
f.password = 'Password1!'
|
||||
end.submit
|
||||
page.uri.to_s.match("http://single-signon-#{space}.cfapps.pez.pivotal.io/Home/About") or raise "Should have redirected to About"
|
||||
page.body.match('Your About page') or raise 'Should now allow testgroup access'
|
||||
|
||||
page = page.link_with(:href => /Contact/).click
|
||||
page.body.match('Insufficient permissions') or raise 'Should not allow testgroup1 access'
|
||||
|
||||
page = page.link_with(:href => /InvokeJwtSample/).click
|
||||
page.body.match('Invoke Jwt Sample Application') or raise 'Should allow jwt access'
|
||||
values = JSON.parse(page.search('h3').text)
|
||||
values == ["value1","value2"] or raise 'Should display values from jwt api'
|
||||
|
||||
puts "Test Passed"
|
|
@ -1,40 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/dotnet2.0
|
||||
inputs:
|
||||
- name: cf-space
|
||||
- name: samples
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -exc
|
||||
- |
|
||||
./cf-space/login
|
||||
. ./cf-space/variables
|
||||
|
||||
if [ ! -z "$CREATE_SERVICE" ]; then
|
||||
cf create-service $(echo $CREATE_SERVICE | sed "s/WhaleDB/WhaleDB$SPACE/g")
|
||||
fi
|
||||
if [ ! -z "$CREATE_CUPS" ]; then
|
||||
cf cups $(echo $CREATE_CUPS | sed "s/\${SPACE}/$SPACE/g")
|
||||
fi
|
||||
|
||||
set +x
|
||||
while [ `cf services | grep 'in progress' | wc -l | sed 's/ //g'` != 0 ]; do
|
||||
echo 'Waiting for services to start'
|
||||
cf services | grep 'in progress'
|
||||
echo
|
||||
sleep 5
|
||||
done
|
||||
|
||||
if [ `cf services | grep 'create failed' | wc -l | sed 's/ //g'` != 0 ]; then
|
||||
echo 'Some services failed to start'
|
||||
cf services
|
||||
echo
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cf services
|
|
@ -1,25 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/cf-cli
|
||||
inputs:
|
||||
- name: cf-space
|
||||
- name: samples
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -exc
|
||||
- |
|
||||
./cf-space/login
|
||||
. ./cf-space/variables
|
||||
|
||||
cf target -s shoetree-system
|
||||
cf map-route whale-db cfapps.pez.pivotal.io --hostname whale-db-${SPACE}
|
||||
|
||||
cf target -s $SPACE
|
||||
|
||||
set +x
|
||||
echo "cf create-service-broker WhaleDB${SPACE} admin [ADMIN_PASSWORD] https://whale-db-${SPACE}.cfapps.pez.pivotal.io --space-scoped"
|
||||
cf create-service-broker WhaleDB${SPACE} admin ${ADMIN_PASSWORD} https://whale-db-${SPACE}.cfapps.pez.pivotal.io --space-scoped
|
|
@ -1,11 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/cf-cli
|
||||
inputs:
|
||||
- name: steeltoe-ci
|
||||
- name: cf-space
|
||||
run:
|
||||
path: steeltoe-ci/scripts/delete-space.sh
|
|
@ -1,23 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/dotnet2.0
|
||||
inputs:
|
||||
- name: samples
|
||||
- name: cf-space
|
||||
outputs:
|
||||
- name: publish
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -exc
|
||||
- |
|
||||
. ./cf-space/variables
|
||||
export PUBLISH_DIR=$PWD/publish
|
||||
cp $SOURCE_DIR/$MANIFEST_YAML $PUBLISH_DIR/
|
||||
cd $SOURCE_DIR
|
||||
dotnet --version
|
||||
dotnet restore
|
||||
dotnet publish --output $PUBLISH_DIR --configuration Release --framework $FRAMEWORK --runtime $RUNTIME
|
|
@ -1,21 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/dotnet2.0
|
||||
inputs:
|
||||
- name: cf-space
|
||||
- name: publish
|
||||
outputs:
|
||||
- name: cf-push
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -exc
|
||||
- |
|
||||
./cf-space/login
|
||||
. ./cf-space/variables
|
||||
export APPNAME=${APPNAME:-testapp}
|
||||
cf push $APPNAME -s $STACK -f publish/$MANIFEST_YAML -p publish --hostname $APPNAME-$SPACE
|
||||
cf app $APPNAME | grep '^routes:' | awk '{print $2}' > cf-push/url
|
|
@ -1,28 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: openjdk
|
||||
inputs:
|
||||
- name: cf-space
|
||||
- name: uaa
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -euxc
|
||||
- |
|
||||
curl -L 'https://cli.run.pivotal.io/stable?release=linux64-binary&source=github' | tar -zx -C /usr/local/bin/
|
||||
./cf-space/login
|
||||
. ./cf-space/variables
|
||||
|
||||
cd uaa/
|
||||
export TERM=dumb
|
||||
./gradlew :cloudfoundry-identity-uaa:war
|
||||
cf push myuaa --no-start -m 1024M -p uaa/build/libs/cloudfoundry-identity-uaa-*.war --hostname myuaa-${SPACE} -b https://github.com/cloudfoundry/java-buildpack.git
|
||||
cf set-env myuaa SPRING_PROFILES_ACTIVE default,hsqldb
|
||||
cf set-env myuaa UAA_URL https://myuaa-${SPACE}.cfapps.pez.pivotal.io
|
||||
cf set-env myuaa LOGIN_URL https://myuaa-${SPACE}.cfapps.pez.pivotal.io
|
||||
cf set-env myuaa JBP_CONFIG_SPRING_AUTO_RECONFIGURATION '[enabled: false]'
|
||||
cf set-env myuaa JBP_CONFIG_TOMCAT '{tomcat: { version: 7.0.+ }}'
|
||||
cf start myuaa
|
|
@ -1,27 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/ruby
|
||||
inputs:
|
||||
- name: cf-space
|
||||
outputs:
|
||||
- name: cf-app-login
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -euxc
|
||||
- |
|
||||
curl -L 'https://cli.run.pivotal.io/stable?release=linux64-binary&source=github' | tar -zx -C /usr/local/bin/
|
||||
./cf-space/login
|
||||
. ./cf-space/variables
|
||||
|
||||
uaac target https://myuaa-${SPACE}.cfapps.pez.pivotal.io
|
||||
uaac token client get admin -s adminsecret
|
||||
uaac contexts
|
||||
uaac group add testgroup || true
|
||||
uaac user add user${SPACE} --given_name Integration --family_name Test --emails test@testcloud.com --password Password1!
|
||||
uaac member add testgroup user${SPACE}
|
||||
uaac client add ${SPACE}TestApp --name ${SPACE}TestApp --scope cloud_controller.read,cloud_controller_service_permissions.read,openid,testgroup --authorized_grant_types authorization_code,refresh_token --authorities uaa.resource --redirect_uri http://single-signon-${SPACE}.cfapps.pez.pivotal.io/signin-cloudfoundry --autoapprove cloud_controller.read,cloud_controller_service_permissions.read,openid,testgroup --secret ${SPACE}TestApp
|
||||
echo "{\"username\":\"user${SPACE}\",\"password\":\"Password1!\"}" > cf-app-login/login.json
|
|
@ -1,11 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/cf-cli
|
||||
inputs:
|
||||
- name: steeltoe-ci
|
||||
- name: cf-push
|
||||
run:
|
||||
path: steeltoe-ci/scripts/test-app.sh
|
|
@ -1,16 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/ruby
|
||||
inputs:
|
||||
- name: steeltoe-ci
|
||||
- name: cf-space
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -euxc
|
||||
- |
|
||||
. ./cf-space/variables
|
||||
./steeltoe-ci/scripts/test-$FILENAME.rb
|
|
@ -1,19 +0,0 @@
|
|||
---
|
||||
platform: linux
|
||||
image_resource:
|
||||
type: docker-image
|
||||
source:
|
||||
repository: steeltoeoss/cf-cli
|
||||
inputs:
|
||||
- name: cf-space
|
||||
- name: samples
|
||||
run:
|
||||
path: sh
|
||||
args:
|
||||
- -exc
|
||||
- |
|
||||
./cf-space/login || true
|
||||
. ./cf-space/variables
|
||||
|
||||
cf target -s shoetree-system
|
||||
cf unmap-route whale-db cfapps.pez.pivotal.io --hostname whale-db-${SPACE}
|
|
@ -1,8 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
basedir=$(dirname $0)
|
||||
for dfile in $basedir/dockerfiles/*/Dockerfile; do
|
||||
name=$(basename $(dirname $dfile))
|
||||
docker build -t steeltoeoss/$name $basedir/dockerfiles/$name || exit
|
||||
docker push steeltoeoss/$name || exit
|
||||
done
|
|
@ -1,8 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
basedir=$(dirname $0)
|
||||
for file in $basedir/pipelines/*.yml; do
|
||||
base=$(basename $file .yml)
|
||||
echo $base
|
||||
fly -t steeltoe set-pipeline -l <(lpass show --notes 'Shared-Steeltoe/concourse.yml') -p $base -c $file
|
||||
done
|
Загрузка…
Ссылка в новой задаче