Skip to content

Commit ea444ff

Browse files
committed
chore: migrate from circleci and docker hub to github actions and ghcr
1 parent 6d431f3 commit ea444ff

File tree

4 files changed

+54
-60
lines changed

4 files changed

+54
-60
lines changed

.circleci/config.yml

Lines changed: 0 additions & 58 deletions
This file was deleted.

.github/workflows/publish.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
2+
on:
3+
push:
4+
branches:
5+
- master
6+
- chore-github-actions # TODO: Remove before merging
7+
schedule:
8+
- cron: "0 5 * * 1"
9+
10+
name: publish
11+
12+
jobs:
13+
test:
14+
name: Build Docker image
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v4
18+
- name: Login to GitHub Container Registry
19+
uses: docker/login-action@v3
20+
with:
21+
registry: ghcr.io
22+
username: ${{ github.actor }}
23+
password: ${{ secrets.GITHUB_TOKEN }}
24+
- name: Build validator image
25+
run: |
26+
docker build \
27+
--no-cache \
28+
--tag ghcr.io/spaceapi/validator:latest \
29+
--tag ghcr.io/spaceapi/validator:$GITHUB_REF_NAME \
30+
--label "org.opencontainers.image.source=$GITHUB_SERVER_URL/$GITHUB_REPOSITORY" \
31+
.
32+
- name: Publish validator image
33+
run: |
34+
docker push -a ghcr.io/spaceapi/validator

.github/workflows/test.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
2+
on: push
3+
4+
name: test
5+
6+
jobs:
7+
test:
8+
name: Run tests
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v4
12+
- name: Setup latest Go
13+
uses: actions/setup-go@v5
14+
with:
15+
go-version: stable
16+
- name: Run tests
17+
run: |
18+
go test ./...

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ be dual licensed as above, without any additional terms or conditions.
100100
<!-- Badges -->
101101
[circle-ci]: https://circleci.com/gh/SpaceApi/validator/tree/master
102102
[circle-ci-badge]: https://circleci.com/gh/SpaceApi/validator/tree/master.svg?style=shield
103-
[docker-image]: https://hub.docker.com/r/spaceapi/validator/
104-
[docker-image-badge]: https://img.shields.io/docker/pulls/spaceapi/validator.svg
103+
[docker-image]: https://github.com/SpaceApi/validator/pkgs/container/validator
104+
[docker-image-badge]: https://img.shields.io/badge/container%20image-ghcr.io/spaceapi/validator-blue.svg
105105
[go-report-card]: https://goreportcard.com/report/github.com/spaceapi/validator
106106
[go-report-card-badge]: https://goreportcard.com/badge/github.com/spaceapi/validator

0 commit comments

Comments
 (0)