Skip to content

Commit

Permalink
Merge branch 'create-build-workflow' of https://github.com/akyriako/d…
Browse files Browse the repository at this point in the history
…ocs-next into create-build-workflow
  • Loading branch information
Kyriakos Akriotis committed Jul 9, 2024
2 parents 2ad50ed + d1bd593 commit b8f67ee
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 16 deletions.
45 changes: 30 additions & 15 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: Checkout code
- name: Checkout
uses: actions/checkout@v2

- name: Setup Node.js
- name: Setup NodeJS
uses: actions/setup-node@v2
with:
node-version: 18 # Use Node.js 18 here

- name: Install dependencies
- name: Install Dependencies
run: npm install

- name: Build site
- name: Build App
env:
TYPESENSE_PROTOCOL: ${{ vars.TYPESENSE_PROTOCOL }}
TYPESENSE_HOST: ${{ vars.TYPESENSE_HOST }}
Expand All @@ -36,15 +36,15 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Set up Docker Buildx
- name: Setup Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v1

- name: Get SHA
- name: Get Commit Hash
id: commit_hash
uses: prompt/actions-commit-hash@v3
- uses: docker/setup-buildx-action@v3
- name: Build and push
- name: Build and Push (Docker Image)
id: docker_build
uses: docker/build-push-action@v2
with:
Expand All @@ -55,13 +55,28 @@ jobs:
${{ secrets.DOCKERHUB_USERNAME }}/${{ vars.IMG_NAME }}:latest
${{ secrets.DOCKERHUB_USERNAME }}/${{ vars.IMG_NAME }}:${{ steps.commit_hash.outputs.short }}
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}
# - name: Image Digest
# run: echo ${{ steps.docker_build.outputs.digest }}

# - name: Build and push
# uses: docker/build-push-action@v5
# with:
# push: true
# tags: akyriako78/docs-next-preview:0.0.1

update-tag:
needs: build
environment: preview
runs-on: ubuntu-latest
steps:
- name: Get Commit Hash
id: commit_hash
uses: prompt/actions-commit-hash@v3
- name: Show Commit Hash Digest
run: echo ${{ steps.commit_hash.outputs.short }}
- name: Update Image Tag
uses: cheelim1/[email protected]
with:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
REPO_NAME: 'docs-next-charts'
REPO_OWNER: 'akyriako'
FILE_PATH: 'chart/values.yaml'
IMAGE_TAG: ${{ steps.commit_hash.outputs.short }}




2 changes: 1 addition & 1 deletion docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import type { Config } from '@docusaurus/types';
import type * as Preset from '@docusaurus/preset-classic';

const config: Config = {
title: 'Architecture Center docs-next',
title: 'Architecture Center',
tagline: 'Best Practices & Blueprints',
favicon: 'img/favicon.ico',

Expand Down

0 comments on commit b8f67ee

Please sign in to comment.