fix: use REGISTRY and GIT_REMOTE vars, point to git2.lunarfront.tech
All checks were successful
CI / ci (pull_request) Successful in 1m27s
CI / e2e (pull_request) Successful in 1m18s

This commit is contained in:
Ryan Moon
2026-04-02 19:50:53 -05:00
parent 9fc42b7881
commit 59ea9557d1

View File

@@ -13,6 +13,9 @@ jobs:
build: build:
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: "!startsWith(github.event.head_commit.message, 'chore: bump version')" if: "!startsWith(github.event.head_commit.message, 'chore: bump version')"
env:
REGISTRY: git2.lunarfront.tech
GIT_REMOTE: git2.lunarfront.tech
steps: steps:
- name: Checkout - name: Checkout
@@ -50,7 +53,7 @@ jobs:
echo "version=$VERSION" >> $GITHUB_OUTPUT echo "version=$VERSION" >> $GITHUB_OUTPUT
- name: Login to registry - name: Login to registry
run: echo "${{ secrets.REGISTRY_TOKEN }}" | docker login registry.lunarfront.tech -u ryan --password-stdin run: echo "${{ secrets.REGISTRY_TOKEN }}" | docker login $REGISTRY -u ryan --password-stdin
- name: Build and push backend - name: Build and push backend
run: | run: |
@@ -58,32 +61,32 @@ jobs:
SHA=$(git rev-parse --short HEAD) SHA=$(git rev-parse --short HEAD)
docker build \ docker build \
--build-arg APP_VERSION=$VERSION \ --build-arg APP_VERSION=$VERSION \
-t registry.lunarfront.tech/ryan/lunarfront-app:$VERSION \ -t $REGISTRY/ryan/lunarfront-app:$VERSION \
-t registry.lunarfront.tech/ryan/lunarfront-app:$SHA \ -t $REGISTRY/ryan/lunarfront-app:$SHA \
-t registry.lunarfront.tech/ryan/lunarfront-app:latest \ -t $REGISTRY/ryan/lunarfront-app:latest \
-f Dockerfile . -f Dockerfile .
docker push registry.lunarfront.tech/ryan/lunarfront-app:$VERSION docker push $REGISTRY/ryan/lunarfront-app:$VERSION
docker push registry.lunarfront.tech/ryan/lunarfront-app:$SHA docker push $REGISTRY/ryan/lunarfront-app:$SHA
docker push registry.lunarfront.tech/ryan/lunarfront-app:latest docker push $REGISTRY/ryan/lunarfront-app:latest
- name: Build and push frontend - name: Build and push frontend
run: | run: |
VERSION=${{ steps.version.outputs.version }} VERSION=${{ steps.version.outputs.version }}
SHA=$(git rev-parse --short HEAD) SHA=$(git rev-parse --short HEAD)
docker build \ docker build \
-t registry.lunarfront.tech/ryan/lunarfront-frontend:$VERSION \ -t $REGISTRY/ryan/lunarfront-frontend:$VERSION \
-t registry.lunarfront.tech/ryan/lunarfront-frontend:$SHA \ -t $REGISTRY/ryan/lunarfront-frontend:$SHA \
-t registry.lunarfront.tech/ryan/lunarfront-frontend:latest \ -t $REGISTRY/ryan/lunarfront-frontend:latest \
-f Dockerfile.frontend . -f Dockerfile.frontend .
docker push registry.lunarfront.tech/ryan/lunarfront-frontend:$VERSION docker push $REGISTRY/ryan/lunarfront-frontend:$VERSION
docker push registry.lunarfront.tech/ryan/lunarfront-frontend:$SHA docker push $REGISTRY/ryan/lunarfront-frontend:$SHA
docker push registry.lunarfront.tech/ryan/lunarfront-frontend:latest docker push $REGISTRY/ryan/lunarfront-frontend:latest
- name: Commit version bump - name: Commit version bump
run: | run: |
git config user.name "lunarfront-bot" git config user.name "lunarfront-bot"
git config user.email "bot@lunarfront.tech" git config user.email "bot@lunarfront.tech"
git remote set-url origin https://lunarfront-bot:${{ secrets.BOT_TOKEN }}@git.lunarfront.tech/ryan/lunarfront-app.git git remote set-url origin https://lunarfront-bot:${{ secrets.BOT_TOKEN }}@$GIT_REMOTE/ryan/lunarfront-app.git
git add packages/backend/package.json git add packages/backend/package.json
git commit -m "chore: bump version to v${{ steps.version.outputs.version }}" git commit -m "chore: bump version to v${{ steps.version.outputs.version }}"
git pull --rebase origin main git pull --rebase origin main
@@ -91,4 +94,4 @@ jobs:
- name: Logout - name: Logout
if: always() if: always()
run: docker logout registry.lunarfront.tech run: docker logout $REGISTRY