Last active
June 4, 2019 05:00
-
-
Save anthonywu/3cca55940968833623aae71fe4291cc3 to your computer and use it in GitHub Desktop.
Cloudflare Workers wrangler CLI workspace
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:bionic-20190515 | |
# rustup: requires curl or wget | |
# wrangler: cargo install requires gcc, pkg-config and libssl-dev | |
# wrangler generate: requires git | |
RUN apt update && \ | |
apt install -qy curl emacs gcc git libssl-dev pkg-config wget && \ | |
apt -y full-upgrade | |
# wrangler build: requires npm nodejs | |
# this step is flaky due to dependency conflicts | |
RUN apt install -qy npm nodejs | |
RUN apt clean && apt -y autoremove | |
RUN curl https://sh.rustup.rs -o ./install_rustup.sh && \ | |
chmod +x install_rustup.sh && \ | |
./install_rustup.sh -y && \ | |
rm install_rustup.sh | |
ENV PATH="$HOME/.cargo/bin:$PATH" | |
RUN /root/.cargo/bin/cargo install wrangler | |
COPY bashrc.sh /root/.bashrc | |
# resources/private/ contains the files that have account and api keys | |
# see https://workers.cloudflare.com/docs/quickstart/api-keys/ | |
# please create resources/private/wrangler_config.toml with this format: | |
# | |
# email = "[email protected]" | |
# api_key = "secretvalue" | |
# account_id = "secretvalue" | |
COPY resources/private/wrangler_config.toml /root/.wrangler/config/default.toml |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment