Skip to content

CI configuration - #101

Open
mateusz-rutski-red wants to merge 1 commit into
LibertyGlobal:masterfrom
mateusz-rutski-red:local/fork/actions
Open

CI configuration#101
mateusz-rutski-red wants to merge 1 commit into
LibertyGlobal:masterfrom
mateusz-rutski-red:local/fork/actions

Conversation

@mateusz-rutski-red

@mateusz-rutski-red mateusz-rutski-red commented Jan 23, 2023

Copy link
Copy Markdown

Create Github Actions CI configuration for image push to Docker Hub

Configure workflow env variables to specify registry URL and namespace, by default images are pushed to Docker Hub in my personal namespace.

Configure authentication with registry by specifying project's secret variables (username and password)

@lg-vbo-hubot

Copy link
Copy Markdown

Can one of the admins verify this patch?

runs-on: ubuntu-20.04
if: "!contains(github.event.head_commit.message, '[ci skip]')"

services:

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For some reason the maven plugin io.fabric8:docker-maven-plugin which runs the following containers does not work within github worker. This declaration does that instead, and maven plugin execution is disabled via -Ddocker.skip=true flag


- name: Build and Test
run:
./mvnw --batch-mode --update-snapshots deploy

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added maven wrapper to ensure maven version consistency regardless of underlying github worker environment which executes our workflow.

Comment thread pom.xml
</executions>
</plugin>
<plugin>
<artifactId>maven-deploy-plugin</artifactId>

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've added a possibility of skipping maven artifact upload, since we don't need it to upload the image.


env:
REGISTRY_URL: docker.io
REGISTRY_NAMESPACE: mrutski

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please set the value to '${{ secrets.DOCKER_REGISTRY_USERNAME }}'?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants