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

fix: add Github workflow to publish e2e Docker image #145

Merged
merged 3 commits into from
Apr 11, 2024
Merged
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
31 changes: 31 additions & 0 deletions .github/workflows/publish-docker-image-e2e.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Publish Docker Image (e2e tests)

on:
workflow_dispatch:
inputs:
tag:
description: 'Docker Tag'
required: true
default: 'latest'

jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v2

- name: Log in to GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push Docker image
uses: docker/build-push-action@v2
with:
context: .
file: e2e.Dockerfile
push: true
tags: ghcr.io/${{ github.repository }}/aio-lib-state-e2e-tests:${{ github.event.inputs.tag }}
22 changes: 22 additions & 0 deletions e2e/e2e.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,28 @@ ADOBE_STATE_STORE_ENDPOINT_PROD=127.0.0.1:8080

Substitute the host with `host.docker.internal` if you are testing with the Dockerized version of the e2e tests.

## Canary Testing

You might have to connect to internal servers for your e2e testing.

For `prod`, use these two environment variables:

```sh
# do not use the scheme for endpoints
ADOBE_STATE_STORE_ENDPOINT_PROD=my-prod-server-here.com
# can be omitted as well, since it defaults to prod
AIO_CLI_ENV=prod
```

For `stage`, use these two environment variables:

```sh
# do not use the scheme for endpoints
ADOBE_STATE_STORE_ENDPOINT_STAGE=my-stage-server-here.com
# set the env
AIO_CLI_ENV=stage
```

## Local Run

`npm run e2e`
Expand Down
Loading