Skip to content
This repository has been archived by the owner on Jul 6, 2022. It is now read-only.

Commit

Permalink
merge latest from master (#199)
Browse files Browse the repository at this point in the history
* refactor event function signatures (#147)

* pass around instances and bindings instead of pointers

* Refactor instance encryption/decryption

Previously, encryption and decryption of certain instance
fields was accomplished through special getters and setters.
To use these, you had to pass in a codec. This meant that any
bit of code needing to access these fields needs access to the
codec. Since I'm entertaining changes to the service.Module
interface that will result in modules having access to instance
objects, I wanted a way for modules to be able to extract
information from encrypted instance fields _without_ needing
them to be burdened with additional moving parts-- like codecs.
So this commit refactors instances and the storage layer so that
encryption occurs during instance marshaling and decryption occurs
during instance unmarshaling.

* Refactor binding encryption/decryption

Previously, encryption and decryption of certain binding
fields was accomplished through special getters and setters.
To use these, you had to pass in a codec. This meant that any
bit of code needing to access these fields needs access to the
codec. Since I'm entertaining changes to the service.Module
interface that will result in modules having access to binding
objects, I wanted a way for modules to be able to extract
information from encrypted binding fields _without_ needing
them to be burdened with additional moving parts-- like codecs.
So this commit refactors bindings and the storage layer so that
encryption occurs during bindings marshaling and decryption occurs
during bindings unmarshaling.

* clean up a few errant lint errors

* pass instance to provisioning steps

* pass instance to deprovisioning steps

* make bind and unbind accept instances as arguments

* get defensive about possible unanticipated modifications to instances by module code

* pass instance to updating steps

* minor lint fixes

* refactor lifecycle tests

* Firewall rule parameterization (#152)

* Refactor to support allowing firewall rules.

Fixes: #146

Changes to suport optional parameters to allow specifying start
and end IP address for firewall rules on MySQL, PostgreSQL and
MSSQL. Previously, this defaulted to allow any connection. This
isn't ecure in practice, so allowing the customer to specify desired
rules. Also changed the default to 0.0.0.0 for both, which results in
only Azure internal addresses. Added some parameter validation
for the firewall values as well:

* Valid IPV4 addresses
* Start <= End

Extracted a method to build the arm template parameter map. Providing
empty strings is invalid for the ARM template, so only including
when non-empty.

Added parameters to the lifecycle tests to allow running them
from local machines (will need ao enhance the charts in helm-charts)

Added some tests.

* Fixing merge conflicts

* Test cleanup

* json field cleanup

* Resolving code review comments

* error message cleanup

* error message cleanup

* specify firewall rules for relational databased in example manifests

* Few minor corrections to the Quickstart (#136)

* Correcting the az ad sp delete command

* Update quickstart-minikube.md

Remove a leading $ from a few bash commands. copy paste on mac is messed up :-)

* Update quickstart-minikube.md

Clarification around logging in to WordPress

* restoring prompts in quickstart

* minor punctuation fix

* removing distracting echo command

* make prompts used consistently

* kick of redis tests sooner (#155)

* s/module lifecycle tests/service lifecycle tests/g (#156)

* make storage know how to deal with service-specific types (#153)

* don't use codec where we don't need it anymore (#161)

* Updating CircleCI to define DOCKER_REPO env var (#167)

* Updating CircleCI to define REGISTRY env var

We previously set the REGISTRY environment variable in a deploy script.
When that was removed to streamline the release process, we need to
define it in Circle. Added two environment blocks to the publish-rc-images
and publish-release-images jobs.

Fixes: 145

* Qualified registry with docker.io

* Changed REGISTRY to DOCKER_REPO

* s/context/details/g (#163)

* make fake bind/unbind functionality not rely on standard context

* collapse standard provisioning context onto instance

* do away with (sort of) redundant standard provisioning parameters

* s/provisioning context/instance details/

* s/binding context/binding details/

* fix error handling when standard params aren't expected types

* add comment that adds some clarity to instance comparisons

* don't store credentials as their own field (#169)

* quickstart fixes (#174)

* adding missing docker pushes to release process

* Adding build flags to inject the version and commit (#173)

* Adding build flags to inject the version and commit

This commit injects the version and commit to the OSBA binary. If there
is no version set, then sets the version to “devel”

* Using new variable for version

* Removing redundant setting for main.commit

* Printing version and commit on broker startup

* Adding fields to the log message on startup

* Removing build flags on the CLI builds

* broker doesn't need to hang on to codec (#180)

* remove quotes from devel pseudo-version string (#184)

Merging without CI.

* fix bug decoding tags (#183)

* move version info to avoid import cycle later (#185)

* Adding user-agent string to requests to ARM (#172)

* Adding user-agent string to requests to ARM

* get version for user agent string from version package

* use separate redis clients for storage and async engine (#182)

* Adding ability to filter lifecycle tests (#181)

* Adding ability to filter lifecycle tests

This adds the ability to filter lifecycle tests using an environment
variable (TEST_MODULES). Via this variable, the developer can provide
a comma delimited list of module names and only the test cases matching
that module will be enabled. If the variable is empty, all tests will run.
If an invalid module name is provided, no tests will run.

* fix typo and lint error

* remove unnecessary funtion

* use redis namespaces (#188)

* use redis namespaces for instances and bindings

* use redis namespaces in async engine

* start using lightweight-docker-go image for development tasks (#190)

* simplify ci config (#194)
  • Loading branch information
krancour authored Jan 8, 2018
1 parent c02f968 commit c1d5bc3
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 77 deletions.
41 changes: 0 additions & 41 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,94 +1,53 @@
version: 2
jobs:
lint:
working_directory: ~/go/src/github.com/Azure/open-service-broker-azure
environment:
GOPATH: ~/go
machine: true
steps:
- checkout
- run:
name: Install Dependencies
command: ./scripts/install-deps.sh
- run:
name: Run Lint
command: make lint
verify-vendored-code:
working_directory: ~/go/src/github.com/Azure/open-service-broker-azure
environment:
GOPATH: ~/go
machine: true
steps:
- checkout
- run:
name: Install Dependencies
command: ./scripts/install-deps.sh
- run:
name: Verify Vendored Code
command: make verify-vendored-code
test-unit:
working_directory: ~/go/src/github.com/Azure/open-service-broker-azure
environment:
GOPATH: ~/go
machine: true
steps:
- checkout
- run:
name: Install Dependencies
command: ./scripts/install-deps.sh
- run:
name: Run Unit Tests
command: make test-unit
test-api-compliance:
working_directory: ~/go/src/github.com/Azure/open-service-broker-azure
environment:
GOPATH: ~/go
machine: true
steps:
- checkout
- run:
name: Install Dependencies
command: ./scripts/install-deps.sh
- run:
name: Run API Compliance Tests
command: make test-api-compliance
build:
working_directory: ~/go/src/github.com/Azure/open-service-broker-azure
environment:
GOPATH: ~/go
machine: true
steps:
- checkout
- run:
name: Install Dependencies
command: ./scripts/install-deps.sh
- run:
name: Build Binary & Docker Image
command: make docker-build
test-service-lifecycles:
working_directory: ~/go/src/github.com/Azure/open-service-broker-azure
environment:
GOPATH: ~/go
machine: true
steps:
- checkout
- run:
name: Install Dependencies
command: ./scripts/install-deps.sh
- run:
name: Run Service Lifecycle Tests
command: make test-service-lifecycles
publish-rc-images:
working_directory: ~/go/src/github.com/Azure/open-service-broker-azure
environment:
GOPATH: ~/go
DOCKER_REPO: microsoft/
machine: true
steps:
- checkout
- run:
name: Install Dependencies
command: ./scripts/install-deps.sh
- run:
name: Log in to Docker Hub
command: docker login -u "${DOCKER_HUB_USERNAME}" -p "${DOCKER_HUB_PASSWORD}"
Expand Down
18 changes: 0 additions & 18 deletions Dockerfile.dev

This file was deleted.

15 changes: 6 additions & 9 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,16 @@
version: "3.2"
services:
dev: #
build:
context: .
dockerfile: Dockerfile.dev
image: quay.io/deis/lightweight-docker-go:v0.1.0
working_dir: /go/src/github.com/Azure/open-service-broker-azure
environment:
CGO_ENABLED: 0
volumes:
- .:/go/src/github.com/Azure/open-service-broker-azure
network_mode: host
test: # Like dev, but linked to redis
build:
context: .
dockerfile: Dockerfile.dev
image: quay.io/deis/lightweight-docker-go:v0.1.0
working_dir: /go/src/github.com/Azure/open-service-broker-azure
volumes:
- .:/go/src/github.com/Azure/open-service-broker-azure
links:
Expand All @@ -24,9 +22,8 @@ services:
links:
- test-api-compliance-broker:broker
test-api-compliance-broker:
build:
context: .
dockerfile: Dockerfile.dev
image: quay.io/deis/lightweight-docker-go:v0.1.0
working_dir: /go/src/github.com/Azure/open-service-broker-azure
volumes:
- .:/go/src/github.com/Azure/open-service-broker-azure
command: bash -c 'go run cmd/compliance-test-broker/compliance-test-broker.go'
Expand Down
9 changes: 0 additions & 9 deletions scripts/install-deps.sh

This file was deleted.

0 comments on commit c1d5bc3

Please sign in to comment.