-
Notifications
You must be signed in to change notification settings - Fork 775
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Sally O'Malley <[email protected]>
- Loading branch information
Showing
5 changed files
with
168 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# | ||
# Copyright 2021 The Sigstore Authors. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# This script is copied from sigstore/sigstore | ||
# See https://github.com/sigstore/sigstore/blob/main/test/e2e/dex-config.yml | ||
|
||
issuer: http://127.0.0.1:5556/auth | ||
|
||
storage: | ||
type: memory | ||
|
||
# Configuration for the HTTP endpoints. | ||
web: | ||
http: 0.0.0.0:5556 | ||
|
||
logger: | ||
level: debug | ||
|
||
oauth2: | ||
responseTypes: [ "code" ] | ||
skipApprovalScreen: true | ||
alwaysShowLoginScreen: false | ||
|
||
staticClients: | ||
- id: sigstore | ||
name: 'Sigstore Mock' | ||
public: true | ||
|
||
connectors: | ||
- type: mockCallback | ||
id: mock | ||
name: Mock | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# | ||
# Copyright 2021 The Sigstore Authors. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# This script is copied from sigstore/sigstore | ||
# See https://github.com/sigstore/sigstore/blob/main/test/e2e/docker-compose.yml | ||
|
||
version: "3.8" | ||
services: | ||
vault: | ||
image: quay.io/sallyom/vault:latest | ||
environment: | ||
VAULT_DEV_ROOT_TOKEN_ID: ${VAULT_TOKEN} | ||
ports: | ||
- 8200:8200 | ||
privileged: true | ||
localstack: | ||
image: quay.io/sallyom/localstack:0.12.16 | ||
ports: | ||
- 4566:4566 | ||
environment: | ||
- SERVICES=kms | ||
dex: | ||
image: quay.io/sallyom/dexidp-dex:v2.31.0 | ||
ports: | ||
- "5556:5556" | ||
volumes: | ||
- ./dex-config.yml:/etc/dex/dex-config.yml:z | ||
command: ["dex", "serve", "/etc/dex/dex-config.yml"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
#!/bin/bash | ||
# | ||
# Copyright 2021 The Sigstore Authors. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# This script is copied from sigstore/sigstore | ||
# replacing docker-compose with podman-compose | ||
# See https://github.com/sigstore/sigstore/blob/main/test/e2e/e2e-test.sh | ||
|
||
set -ex | ||
|
||
cleanup() { | ||
echo "cleanup" | ||
$COMPOSE_CMD down | ||
} | ||
|
||
run=$1 | ||
if [ $run = "cleanup" ] | ||
then | ||
cleanup | ||
else | ||
trap cleanup ERR | ||
|
||
export VAULT_TOKEN=testtoken | ||
export VAULT_ADDR=http://localhost:8200/ | ||
|
||
# The following env vars are required only when running sigstore e2es | ||
# These are not required for sigstore setup | ||
export AWS_ACCESS_KEY_ID=test | ||
export AWS_SECRET_ACCESS_KEY=test | ||
export AWS_REGION=us-east-1 | ||
export AWS_ENDPOINT=localhost:4566 | ||
export AWS_TLS_INSECURE_SKIP_VERIFY=1 | ||
export OIDC_ISSUER=http://127.0.0.1:5556/auth | ||
export OIDC_ID=sigstore | ||
|
||
echo "starting services" | ||
|
||
$COMPOSE_CMD up -d | ||
|
||
count=0 | ||
|
||
echo -n "waiting up to 60 sec for system to start" | ||
until [ $($COMPOSE_CMD logs localstack | grep -c Ready) == 1 ]; | ||
do | ||
if [ $count -eq 12 ]; then | ||
echo "! timeout reached" | ||
exit 1 | ||
else | ||
echo -n "." | ||
sleep 5 | ||
let 'count+=1' | ||
fi | ||
done | ||
|
||
echo "sigstore setup complete" | ||
fi |