mirror of
https://github.com/cloudflare/wrangler-action.git
synced 2024-11-22 01:53:24 +01:00
Updates from testing locally
This commit is contained in:
parent
b52c9462b3
commit
32bb6468e7
2 changed files with 10 additions and 3 deletions
|
@ -1,7 +1,5 @@
|
||||||
FROM node:12
|
FROM node:12
|
||||||
ENV XDG_CONFIG_HOME /github/workspace
|
ENV XDG_CONFIG_HOME /github/workspace
|
||||||
RUN "curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.0/install.sh | bash"
|
|
||||||
RUN "nvm install latest"
|
|
||||||
ENV WRANGLER_HOME /github/workspace
|
ENV WRANGLER_HOME /github/workspace
|
||||||
COPY entrypoint.sh /entrypoint.sh
|
COPY entrypoint.sh /entrypoint.sh
|
||||||
ENTRYPOINT ["/entrypoint.sh"]
|
ENTRYPOINT ["/entrypoint.sh"]
|
||||||
|
|
|
@ -2,6 +2,14 @@
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
export HOME="/github/workspace"
|
||||||
|
export NVM_DIR="/github/workspace/nvm"
|
||||||
|
export WRANGLER_HOME="/github/workspace"
|
||||||
|
|
||||||
|
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.0/install.sh | bash
|
||||||
|
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
||||||
|
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
||||||
|
|
||||||
if [ -n "$CLOUDFLARE_API_KEY" ]; then
|
if [ -n "$CLOUDFLARE_API_KEY" ]; then
|
||||||
echo "CLOUDFLARE_API_KEY env var needs to be set. Add this field in the 'Secrets' section of your repo's settings."
|
echo "CLOUDFLARE_API_KEY env var needs to be set. Add this field in the 'Secrets' section of your repo's settings."
|
||||||
exit 1
|
exit 1
|
||||||
|
@ -12,7 +20,8 @@ if [ -n "$CLOUDFLARE_EMAIL" ]; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
npm i
|
|
||||||
npm i @cloudflare/wrangler -g
|
npm i @cloudflare/wrangler -g
|
||||||
|
npm i
|
||||||
|
|
||||||
wrangler whoami
|
wrangler whoami
|
||||||
wrangler publish
|
wrangler publish
|
||||||
|
|
Loading…
Reference in a new issue