add .npmrc

This commit is contained in:
2025-12-19 12:02:53 -05:00
parent b39a07918a
commit 7111fd4d2a
3 changed files with 17 additions and 1 deletions

View File

@@ -12,7 +12,7 @@ RUN apk -U --no-cache add \
doas doas-sudo-shim \ doas doas-sudo-shim \
bash less openvi \ bash less openvi \
coreutils grep gawk perl \ coreutils grep gawk perl \
curl curl bind-tools
RUN adduser -h /home/cli -s /bin/bash -D cli cli && \ RUN adduser -h /home/cli -s /bin/bash -D cli cli && \
addgroup cli wheel && \ addgroup cli wheel && \

View File

@@ -11,14 +11,28 @@ tasks:
default: default:
cmds: cmds:
- task: build - task: build
build: build:
desc: build a new image; use CLI_ARGS to pass additional arguments (build -- --no-cache). desc: build a new image; use CLI_ARGS to pass additional arguments (build -- --no-cache).
cmds: cmds:
- (podman manifest exists {{.IMAGE}}:{{.TAG}} && podman manifest rm {{.IMAGE}}:{{.TAG}}) || true - (podman manifest exists {{.IMAGE}}:{{.TAG}} && podman manifest rm {{.IMAGE}}:{{.TAG}}) || true
- podman manifest create {{.IMAGE}}:{{.TAG}} - podman manifest create {{.IMAGE}}:{{.TAG}}
- podman build {{.CLI_ARGS}} --platform linux/amd64,linux/arm64 --manifest {{.IMAGE}}:{{.TAG}} {{.CLI_ARGS}} -f Dockerfile ctx - podman build {{.CLI_ARGS}} --platform linux/amd64,linux/arm64 --manifest {{.IMAGE}}:{{.TAG}} {{.CLI_ARGS}} -f Dockerfile ctx
publish: publish:
desc: publish the image with the default tag, 'current', and 'latest'
cmds:
- task: _publish
- task: _publish
vars:
ALT_TAG: 'current'
- task: _publish
vars:
ALT_TAG: 'latest'
_publish:
desc: publish the image desc: publish the image
internal: true
cmds: cmds:
- podman tag {{.IMAGE}}:{{.TAG}} {{.REGISTRY}}/{{.IMAGE}}:{{.ALT_TAG}} - podman tag {{.IMAGE}}:{{.TAG}} {{.REGISTRY}}/{{.IMAGE}}:{{.ALT_TAG}}
- echo "${{.REGISTRY_PASS_VAR}}" | podman login {{.REGISTRY}} -u {{.REGISTRY_USER}} --password-stdin - echo "${{.REGISTRY_PASS_VAR}}" | podman login {{.REGISTRY}} -u {{.REGISTRY_USER}} --password-stdin
@@ -29,3 +43,4 @@ tasks:
REGISTRY: ghcr.io REGISTRY: ghcr.io
REGISTRY_USER: jswank REGISTRY_USER: jswank
ALT_TAG: '{{.TAG}}' ALT_TAG: '{{.TAG}}'

1
ctx/home/.npmrc Normal file
View File

@@ -0,0 +1 @@
prefix=~/.local