Skip to content

Commit

Permalink
new yolk
Browse files Browse the repository at this point in the history
  • Loading branch information
shaikhnedab committed Feb 5, 2024
1 parent 1df63b1 commit 7b73635
Show file tree
Hide file tree
Showing 3 changed files with 58 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/nodejs-alpine-pnpm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: build nodejs-alpine-pnpm
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * 1"
push:
branches:
- main
paths:
- nodejs-alpine-pnpm/**
jobs:
push:
name: "yolks:nodejs-alpine-pnpm_${{ matrix.tag }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
tag:
- 16
steps:
- uses: actions/checkout@v3
- uses: docker/setup-buildx-action@v2
with:
version: "v0.8.2"
buildkitd-flags: --debug
- uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- uses: docker/build-push-action@v2
with:
context: ./nodejs-alpine-pnpm
file: ./nodejs-alpine-pnpm/${{ matrix.tag }}/Dockerfile
platforms: linux/amd64
push: true
tags: |
ghcr.io/shaikhnedab/yolks:nodejs-alpine-pnpm_${{ matrix.tag }}
File renamed without changes.
20 changes: 20 additions & 0 deletions nodejs-alpine-pnpm/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#!/bin/ash
cd /home/container

# Make internal Docker IP address available to processes.
INTERNAL_IP=$(ip route get 1 | awk '{print $(NF-2);exit}')
export INTERNAL_IP

echo "Node.js Version"
node -v
echo "NPM Version"
npm -v
echo "NPM Install Packages"
npm i

# Replace Startup Variables
MODIFIED_STARTUP=$(echo -e $(echo -e ${STARTUP} | sed -e 's/{{/${/g' -e 's/}}/}/g'))
echo -e ":/home/container$ ${MODIFIED_STARTUP}"

# Run the Server
eval ${MODIFIED_STARTUP}

0 comments on commit 7b73635

Please sign in to comment.