diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile new file mode 100644 index 0000000..0431bdd --- /dev/null +++ b/.devcontainer/Dockerfile @@ -0,0 +1,10 @@ +FROM mcr.microsoft.com/devcontainers/typescript-node:1-20-bullseye + +# Install additional packages. +RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \ + && apt-get -y install --no-install-recommends curl jq \ + && apt-get -y install ca-certificates curl python3-pip python3-dev python3-setuptools python3-wheel \ + && pip install --upgrade pip && pip install requests \ + && sudo rm -rf /var/lib/apt/lists/* + +RUN curl -o pond https://raw.githubusercontent.com/Team-Kujira/pond/main/pond && chmod +x pond && sudo mv pond /usr/local/bin/ diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json new file mode 100644 index 0000000..3776e8f --- /dev/null +++ b/.devcontainer/devcontainer.json @@ -0,0 +1,20 @@ +{ + "name": "Node.hs, TypeScript & Pond", + "build": { + "dockerfile": "Dockerfile", + "context": ".." + }, + + "forwardPorts": [10117, 10157, 5173], + + "postCreateCommand": "pond init && pond start && npm i", + "features": { + "ghcr.io/devcontainers/features/docker-in-docker:2": {} + } + + // Configure tool-specific properties. + // "customizations": {}, + + // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. + // "remoteUser": "root" +} diff --git a/README.md b/README.md index 7ed5054..904b295 100644 --- a/README.md +++ b/README.md @@ -22,3 +22,16 @@ Load the config into your pond-ui app - Wallet connections - Transaction signing & broadcasting + +## Dev Containers + +To open the repository in a VS Code Devcontainer: +- Use VS Code on your local machine +- Install the [Dev Containers VS Code extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers) +- Click on the bottom left and choose to Reopen in Container +- Execute `npm run dev` and you are ready to build + +This will install: +1. Pond +2. Typescript +3. npm \ No newline at end of file