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

feat(e2e): enable maven proxy #4501

Closed
wants to merge 1 commit into from
Closed
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
13 changes: 13 additions & 0 deletions .github/actions/kamel-config-cluster/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,19 @@ runs:

echo "Complete"

#
# Install a Maven Proxy repository
#
- id: install-maven-proxy
name: Install Maven proxy repository
shell: bash
run: |
kubectl create namespace nexus
kubectl apply -f ./.github/actions/kamel-config-cluster/nexus.yaml -n nexus
kubectl rollout status deployment nexus -n nexus --timeout=180s
echo "TEST_ENABLE_NEXUS=true" >> $GITHUB_OUTPUT
echo "Maven proxy repository up and running!"

outputs:
cluster-image-registry-push-host:
description: "The image registry to which to push images"
Expand Down
49 changes: 49 additions & 0 deletions .github/actions/kamel-config-cluster/nexus.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
apiVersion: v1
kind: Service
metadata:
name: nexus
spec:
selector:
app: nexus
ports:
- protocol: TCP
port: 80
targetPort: 8081
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: nexus
spec:
selector:
matchLabels:
app: nexus
template:
metadata:
labels:
app: nexus
spec:
containers:
- name: nexus
image: sonatype/nexus3
ports:
- containerPort: 8081
name: 8081-tcp
livenessProbe:
httpGet:
path: /service/rest/v1/status
port: 8081
initialDelaySeconds: 90
periodSeconds: 3
readinessProbe:
httpGet:
path: /service/rest/v1/status
port: 8081
initialDelaySeconds: 90
periodSeconds: 3
volumeMounts:
- name: nexus-data
mountPath: /nexus-data
volumes:
- name: nexus-data
emptyDir: {}
2 changes: 1 addition & 1 deletion e2e/support/test_nexus_hooks.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ import (
const (
nexusNamespace = "nexus"
nexusService = "nexus"
nexusMavenMirror = "http://nexus.nexus/repository/maven-public/@id=nexus@mirrorOf=central"
nexusMavenMirror = "http://nexus.nexus/@id=nexus@mirrorOf=*"
)

func init() {
Expand Down