diff --git a/.github/workflows/docker-image-build.yml b/.github/workflows/docker-image-build.yml index f02beff1..d850fa57 100644 --- a/.github/workflows/docker-image-build.yml +++ b/.github/workflows/docker-image-build.yml @@ -1,4 +1,4 @@ -name: Build docker image +name: Build and publish docker image on: push: @@ -9,20 +9,8 @@ on: jobs: build: - runs-on: ubuntu-20.04 - steps: - - name: Checkout code - uses: actions/checkout@v2 - - name: Set up QEMU - uses: docker/setup-qemu-action@v1 - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 - with: - version: latest - - name: Login to docker hub - uses: docker/login-action@v1 - with: - username: ${{ secrets.DOCKER_HUB_USERNAME }} - password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} - - name: Build the image - run: bash ./scripts/docker/build + uses: shlinkio/github-actions/.github/workflows/docker-build-and-publish.yml@main + secrets: inherit + with: + image-name: shlinkio/shlink-web-client + version-arg-name: VERSION diff --git a/CHANGELOG.md b/CHANGELOG.md index f2dd09fe..3a20e268 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,23 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org). +## [3.7.3] - 2022-09-13 +### Added +* [#703](https://github.com/shlinkio/shlink-web-client/issues/703) Added support to publish docker image in GHCR. + +### Changed +* *Nothing* + +### Deprecated +* *Nothing* + +### Removed +* *Nothing* + +### Fixed +* [#709](https://github.com/shlinkio/shlink-web-client/issues/709) Fixed visits not being displayed after a large loading has finished. + + ## [3.7.2] - 2022-08-07 ### Added * [#671](https://github.com/shlinkio/shlink-web-client/issues/671) Added proper color-scheme in root element based on selected theme. diff --git a/scripts/docker/build b/scripts/docker/build deleted file mode 100755 index 1a39c9cb..00000000 --- a/scripts/docker/build +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/bash - -set -ex - -PLATFORMS="linux/arm/v7,linux/arm64/v8,linux/amd64" -DOCKER_IMAGE="shlinkio/shlink-web-client" - -if [[ "$GITHUB_REF" == *"develop"* ]]; then - docker buildx build --push \ - --platform ${PLATFORMS} \ - -t ${DOCKER_IMAGE}:latest . - -# If ref is not develop, then this is a tag. Build that docker tag and also "stable" -else - VERSION=${GITHUB_REF#refs/tags/v} - TAGS="-t ${DOCKER_IMAGE}:${VERSION}" - - # Push stable tag only if this is not an alpha or beta release - [[ $GITHUB_REF != *"alpha"* && $GITHUB_REF != *"beta"* ]] && TAGS="${TAGS} -t ${DOCKER_IMAGE}:stable" - - docker buildx build --push \ - --build-arg VERSION=${VERSION} \ - --platform ${PLATFORMS} \ - ${TAGS} . -fi diff --git a/src/visits/reducers/domainVisits.ts b/src/visits/reducers/domainVisits.ts index 3570e023..17ee4f63 100644 --- a/src/visits/reducers/domainVisits.ts +++ b/src/visits/reducers/domainVisits.ts @@ -50,7 +50,7 @@ export default buildReducer({ [GET_DOMAIN_VISITS_START]: () => ({ ...initialState, loading: true }), [GET_DOMAIN_VISITS_ERROR]: (_, { errorData }) => ({ ...initialState, error: true, errorData }), [GET_DOMAIN_VISITS]: (state, { visits, domain, query }) => ( - { ...state, visits, domain, query, loading: false, error: false } + { ...state, visits, domain, query, loading: false, loadingLarge: false, error: false } ), [GET_DOMAIN_VISITS_LARGE]: (state) => ({ ...state, loadingLarge: true }), [GET_DOMAIN_VISITS_CANCEL]: (state) => ({ ...state, cancelLoad: true }), diff --git a/src/visits/reducers/nonOrphanVisits.ts b/src/visits/reducers/nonOrphanVisits.ts index 41d1a5dc..05133800 100644 --- a/src/visits/reducers/nonOrphanVisits.ts +++ b/src/visits/reducers/nonOrphanVisits.ts @@ -45,7 +45,9 @@ const initialState: VisitsInfo = { export default buildReducer({ [GET_NON_ORPHAN_VISITS_START]: () => ({ ...initialState, loading: true }), [GET_NON_ORPHAN_VISITS_ERROR]: (_, { errorData }) => ({ ...initialState, error: true, errorData }), - [GET_NON_ORPHAN_VISITS]: (state, { visits, query }) => ({ ...state, visits, query, loading: false, error: false }), + [GET_NON_ORPHAN_VISITS]: (state, { visits, query }) => ( + { ...state, visits, query, loading: false, loadingLarge: false, error: false } + ), [GET_NON_ORPHAN_VISITS_LARGE]: (state) => ({ ...state, loadingLarge: true }), [GET_NON_ORPHAN_VISITS_CANCEL]: (state) => ({ ...state, cancelLoad: true }), [GET_NON_ORPHAN_VISITS_PROGRESS_CHANGED]: (state, { progress }) => ({ ...state, progress }), diff --git a/src/visits/reducers/orphanVisits.ts b/src/visits/reducers/orphanVisits.ts index 69fec2cd..8b6aee65 100644 --- a/src/visits/reducers/orphanVisits.ts +++ b/src/visits/reducers/orphanVisits.ts @@ -48,7 +48,9 @@ const initialState: VisitsInfo = { export default buildReducer({ [GET_ORPHAN_VISITS_START]: () => ({ ...initialState, loading: true }), [GET_ORPHAN_VISITS_ERROR]: (_, { errorData }) => ({ ...initialState, error: true, errorData }), - [GET_ORPHAN_VISITS]: (state, { visits, query }) => ({ ...state, visits, query, loading: false, error: false }), + [GET_ORPHAN_VISITS]: (state, { visits, query }) => ( + { ...state, visits, query, loading: false, loadingLarge: false, error: false } + ), [GET_ORPHAN_VISITS_LARGE]: (state) => ({ ...state, loadingLarge: true }), [GET_ORPHAN_VISITS_CANCEL]: (state) => ({ ...state, cancelLoad: true }), [GET_ORPHAN_VISITS_PROGRESS_CHANGED]: (state, { progress }) => ({ ...state, progress }), diff --git a/src/visits/reducers/shortUrlVisits.ts b/src/visits/reducers/shortUrlVisits.ts index 9f568768..00327c46 100644 --- a/src/visits/reducers/shortUrlVisits.ts +++ b/src/visits/reducers/shortUrlVisits.ts @@ -53,6 +53,7 @@ export default buildReducer({ domain, query, loading: false, + loadingLarge: false, error: false, }), [GET_SHORT_URL_VISITS_LARGE]: (state) => ({ ...state, loadingLarge: true }), diff --git a/src/visits/reducers/tagVisits.ts b/src/visits/reducers/tagVisits.ts index b57f6836..f2fe6b85 100644 --- a/src/visits/reducers/tagVisits.ts +++ b/src/visits/reducers/tagVisits.ts @@ -46,7 +46,9 @@ const initialState: TagVisits = { export default buildReducer({ [GET_TAG_VISITS_START]: () => ({ ...initialState, loading: true }), [GET_TAG_VISITS_ERROR]: (_, { errorData }) => ({ ...initialState, error: true, errorData }), - [GET_TAG_VISITS]: (state, { visits, tag, query }) => ({ ...state, visits, tag, query, loading: false, error: false }), + [GET_TAG_VISITS]: (state, { visits, tag, query }) => ( + { ...state, visits, tag, query, loading: false, loadingLarge: false, error: false } + ), [GET_TAG_VISITS_LARGE]: (state) => ({ ...state, loadingLarge: true }), [GET_TAG_VISITS_CANCEL]: (state) => ({ ...state, cancelLoad: true }), [GET_TAG_VISITS_PROGRESS_CHANGED]: (state, { progress }) => ({ ...state, progress }),