Skip to content

Selenium CI

Selenium CI #67

name: Selenium CI
on:
workflow_dispatch: # Adds manual trigger
schedule:
# Runs at 05:05 UTC on the 5th day of every month
# ┌───────────── minute (0 - 59)
# │ ┌───────────── hour (0 - 23)
# │ │ ┌───────────── day of the month (1 - 31)
# │ │ │ ┌───────────── month (1 - 12)
# │ │ │ │ ┌───────────── day of the week (0 - 6) (Sunday to Saturday)
# │ │ │ │ │
# │ │ │ │ │
# * * * * *
- cron: '5 5 8 * *'
push:
branches: [ "master" ]
paths:
- 'Docker/selenium-firefox/**'
pull_request:
branches: [ "master" ]
paths:
- 'Docker/selenium-firefox/**'
jobs:
build-docker-image:
runs-on: self-hosted-linux
steps:
- name: Docker login
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Checkout
uses: actions/checkout@v3
- name: Build docker image
run: cd Docker/selenium-firefox && docker build . --file Dockerfile --tag ${{ secrets.DOCKERHUB_USERNAME }}/selenium-firefox:$(date +%s) --tag ${{ secrets.DOCKERHUB_USERNAME }}/selenium-firefox:latest && docker push ${{ secrets.DOCKERHUB_USERNAME }}/selenium-firefox --all-tags