v2
All checks were successful
Push to main / Reset-Version-Tag (push) Successful in 7s

This commit is contained in:
2026-03-05 07:14:39 -07:00
parent c01a6494ca
commit 19dd8f0430
4 changed files with 23 additions and 20 deletions

View File

@@ -10,7 +10,7 @@ jobs:
steps:
- name: Check out repository code
uses: actions/checkout@v3
- run: git tag -d v1 || true
- run: git push --delete origin v1 || true
- run: git tag v1
- run: git tag -d v2 || true
- run: git push --delete origin v2 || true
- run: git tag v2
- run: git push --tags

19
action.js Normal file
View File

@@ -0,0 +1,19 @@
import { execSync, readFileSync } from "fs";
const tag = JSON.parse(
readFileSync("package.json", { encoding: "utf8" }),
).version;
console.log("============= INSTALLING DOCKER ==============");
execSync("curl -fsSL https://get.docker.com -o get-docker.sh");
execSync("sh get-docker.sh");
execSync("rm get-docker.sh");
console.log("======== LOGGING IN TO CONTAINER REPO ========");
execSync(
"docker login $INPUT_CONTAINER_DOMAIN -u $INPUT_LOGIN_USER --password $INPUT_LOGIN_PASS",
);
execSync(
`docker build -t $INPUT_CONTAINER_DOMAIN/$INPUT_CONTAINER_NAME:${tag} --no-cache .`,
);
execSync(`docker push $INPUT_CONTAINER_DOMAIN/$INPUT_CONTAINER_NAME:${tag}`);

View File

@@ -1,13 +0,0 @@
### INSTALL DOCKER
echo "get docker install script"
curl -fsSL https://get.docker.com -o get-docker.sh
echo "run docker install script"
sh get-docker.sh
### LOGIN TO CONTAINER REPO
echo "run docker login"
docker login $INPUT_CONTAINER_DOMAIN -u $INPUT_LOGIN_USER --password $INPUT_LOGIN_PASS
echo "run docker build"
docker build -t $INPUT_CONTAINER_DOMAIN/$INPUT_CONTAINER_NAME:$INPUT_CONTAINER_TAG --no-cache .
echo "run docker push"
docker push $INPUT_CONTAINER_DOMAIN/$INPUT_CONTAINER_NAME:$INPUT_CONTAINER_TAG

View File

@@ -14,11 +14,8 @@ inputs:
container_name:
description: container name (org/package)
required: true
container_tag:
description: container tag (latest)
required: true
runs:
using: "composite"
steps:
- run: $GITHUB_ACTION_PATH/action.sh
- run: node $GITHUB_ACTION_PATH/action.js
shell: bash