Skip to content

chore(deps-dev): bump eslint-plugin-jest from 29.12.0 to 29.12.1 #1225

chore(deps-dev): bump eslint-plugin-jest from 29.12.0 to 29.12.1

chore(deps-dev): bump eslint-plugin-jest from 29.12.0 to 29.12.1 #1225

Workflow file for this run

name: E2E
on:
pull_request:
push:
branches:
- main
schedule:
- cron: '0 5 * * 0'
env:
# The certificate is valid for this host so in order to use "secure" mode we add this to hosts and use for calling central
ROX_HOST: 'central.stackrox'
ROX_PORT: 8000
jobs:
e2e:
name: E2E
runs-on: ubuntu-latest
permissions:
id-token: write # Required for the central-login action which we will test.
steps:
- uses: actions/checkout@v6
- name: Set up hostname
run: |
echo "127.0.0.1 ${ROX_HOST}" | sudo tee -a /etc/hosts >/dev/null
- name: Create k8s Kind Cluster
uses: helm/kind-action@v1
- uses: actions/checkout@v6
with:
repository: stackrox/stackrox
path: stackrox
- name: Install Stackrox
env:
MAIN_IMAGE_TAG: "latest"
SENSOR_HELM_DEPLOY: "true"
ROX_SCANNER_V4: "false"
run: |
stackrox/deploy/k8s/deploy-local.sh
ROX_PASSWORD=$(cat stackrox/deploy/k8s/central-deploy/password)
echo "::add-mask::$ROX_PASSWORD"
echo "ROX_PASSWORD=$ROX_PASSWORD" >> $GITHUB_ENV
echo "ROX_URL=https://${ROX_HOST}:${ROX_PORT}" >> $GITHUB_ENV
- name: Install and trust Central certificate
run: |
# Extract the server certificate and save it as a new CA file
echo | \
openssl s_client -showcerts -servername $ROX_HOST -connect $ROX_HOST:8000 2>/dev/null | \
awk '/-----BEGIN CERTIFICATE-----/,/-----END CERTIFICATE-----/ { print $0 }' > central.crt
# Install the certificate into the system trust store
sudo cp central.crt /usr/local/share/ca-certificates/central.crt
sudo update-ca-certificates
- name: Add machine to machine configuration in Central
run: |
curl -u admin:${ROX_PASSWORD} \
${ROX_URL}/v1/auth/m2m \
-d \
'{
"config": {
"type": "GITHUB_ACTIONS",
"tokenExpirationDuration": "5m",
"mappings": [
{
"key": "sub",
"valueExpression": "repo:stackrox/central-login.*",
"role": "Analyst"
}
]
}
}'
- name: Run central-login action
uses: ./
with:
endpoint: ${{ env.ROX_URL }}
- name: Install roxctl
uses: stackrox/roxctl-installer-action@v1
with:
central-endpoint: ${{ env.ROX_URL }}
central-token: ${{ env.ROX_API_TOKEN }}
- name: Check the current user with roxctl
run: |
roxctl central whoami