Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update SPIRE version in tests to 1.11.0 #211

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 8 additions & 7 deletions .github/tests/it/build.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/bin/bash
set -e

fingerprint () {
# calculate the SHA1 digest of the DER bytes of the certificate using the
Expand Down Expand Up @@ -30,27 +31,27 @@ docker compose exec spire-server ./bin/spire-server entry create \
-parentID "spiffe://example.org/spire/agent/x509pop/${FINGERPRINT}" \
-spiffeID spiffe://example.org/postgres-db \
-selector unix:uid:70 \
-ttl 60
-x509SVIDTTL 60

docker compose exec spire-server ./bin/spire-server entry create \
-parentID "spiffe://example.org/spire/agent/x509pop/${FINGERPRINT}" \
-parentID "spiffe://example.org/spire/agent/x509pop/${FINGERPRINT}" \
-spiffeID spiffe://example.org/mysql-db \
-selector unix:uid:0 \
-ttl 60
-x509SVIDTTL 60

docker compose exec spire-server ./bin/spire-server entry create \
-parentID "spiffe://example.org/spire/agent/x509pop/${FINGERPRINT}" \
-spiffeID spiffe://example.org/client \
-selector unix:uid:72 \
-dns client \
-ttl 100
-dns client \
-x509SVIDTTL 100

docker compose exec spire-server ./bin/spire-server entry create \
-parentID "spiffe://example.org/spire/agent/x509pop/${FINGERPRINT}" \
-spiffeID spiffe://example.org/go-server \
-selector unix:uid:73 \
-dns go-server \
-ttl 3600
-dns go-server \
-x509SVIDTTL 3600

# set ups spire agent
docker compose up spire-agent -d
Expand Down
4 changes: 2 additions & 2 deletions .github/tests/it/change-entry-client-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ restore-entry(){
-parentID $PARENTID \
-spiffeID spiffe://example.org/client \
-selector unix:uid:72 \
-ttl 100 \
-x509SVIDTTL 100 \
-dns client

echo "Entry restored"
Expand Down Expand Up @@ -54,7 +54,7 @@ bad-entry(){
-parentID $PARENTID \
-spiffeID spiffe://example.org/client \
-selector unix:uid:72 \
-ttl 100 \
-x509SVIDTTL 100 \
-dns testuser1

echo "Entry changed, now with dns=testuser1"
Expand Down
4 changes: 2 additions & 2 deletions .github/tests/it/docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
services:
spire-server:
image: ghcr.io/spiffe/spire-server:1.7.0
image: ghcr.io/spiffe/spire-server:1.11.0
hostname: spire-server
volumes:
- ./spire/server:/opt/spire/conf/server
command: ["-config", "/opt/spire/conf/server/server.conf"]

spire-agent:
image: ghcr.io/spiffe/spire-agent:1.7.0
image: ghcr.io/spiffe/spire-agent:1.11.0
depends_on: ["spire-server"]
hostname: spire-agent
volumes:
Expand Down
1 change: 1 addition & 0 deletions .github/tests/it/run-mysql-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ fail(){

testWithParameter(){
var=$(docker compose exec client su client -c "/run/client/mysql-connect.sh \"$1\"")
echo $var

if echo "$var" | grep -q "[email protected]"; then
if [ "$2" -eq 1 ]; then
Expand Down
Loading