ci: install node
This commit is contained in:
parent
f892ac0016
commit
6bc3be829a
1 changed files with 17 additions and 4 deletions
|
|
@ -16,10 +16,20 @@ env:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-and-push:
|
build-and-push:
|
||||||
runs-on: ubntu-server-25.04
|
runs-on: microk8s
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
# Skip post-checkout step that requires node
|
||||||
|
fetch-depth: 1
|
||||||
|
submodules: recursive
|
||||||
|
|
||||||
|
- name: Install Node.js
|
||||||
|
run: |
|
||||||
|
# Install Node.js which is required for the checkout action
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install -y nodejs npm
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
run: |
|
run: |
|
||||||
|
|
@ -54,13 +64,16 @@ jobs:
|
||||||
# Push the image with version tag and latest tag
|
# Push the image with version tag and latest tag
|
||||||
docker push ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.generate_tag.outputs.VERSION_TAG }}
|
docker push ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.generate_tag.outputs.VERSION_TAG }}
|
||||||
docker push ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.generate_tag.outputs.LATEST_TAG }}
|
docker push ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.generate_tag.outputs.LATEST_TAG }}
|
||||||
|
deploy:
|
||||||
deploy:
|
|
||||||
needs: build-and-push
|
needs: build-and-push
|
||||||
runs-on: docker
|
runs-on: microk8s
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
# Skip post-checkout step that requires node
|
||||||
|
fetch-depth: 1
|
||||||
|
submodules: recursive
|
||||||
|
|
||||||
# Generate the same version tag as build-and-push job
|
# Generate the same version tag as build-and-push job
|
||||||
- name: Generate version tag
|
- name: Generate version tag
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue