diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile new file mode 100644 index 0000000..ab1a940 --- /dev/null +++ b/.devcontainer/Dockerfile @@ -0,0 +1,13 @@ +FROM jetpackio/devbox:latest + +# Installing your devbox project +WORKDIR /code +USER ${DEVBOX_USER}:${DEVBOX_USER} +COPY --chown=${DEVBOX_USER}:${DEVBOX_USER} devbox.json devbox.json +COPY --chown=${DEVBOX_USER}:${DEVBOX_USER} devbox.lock devbox.lock + + + +RUN devbox run -- echo "Installed Packages." + +RUN devbox shellenv --init-hook >> ~/.profile diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index de0f60f..e7ae9f1 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -1,27 +1,16 @@ -// For format details, see https://aka.ms/devcontainer.json. For config options, see the -// README at: https://github.com/devcontainers/templates/tree/main/src/alpine { - "name": "Debian", - // Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile - "image": "mcr.microsoft.com/devcontainers/base:debian", - "features": { - "ghcr.io/shyim/devcontainers-features/bun:0": {}, - "ghcr.io/devcontainers/features/git-lfs:1": {}, - "ghcr.io/devcontainers/features/node:1": {}, - "ghcr.io/swift-server-community/swift-devcontainer-features/sqlite:1": {}, - "ghcr.io/devcontainers/features/rust:1": {}, - "ghcr.io/devcontainers/features/docker-in-docker:2": {} - }, - - // Use 'forwardPorts' to make a list of ports inside the container available locally. - // "forwardPorts": [], - - // Use 'postCreateCommand' to run commands after the container is created. - "postCreateCommand": "sudo apt-get update && sudo apt-get install -y zstd", - - // Configure tool-specific properties. - // "customizations": {}, - - // Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root. - // "remoteUser": "root" -} + "name": "Devbox Remote Container", + "build": { + "dockerfile": "./Dockerfile", + "context": ".." + }, + "customizations": { + "vscode": { + "settings": {}, + "extensions": [ + "jetpack-io.devbox" + ] + } + }, + "remoteUser": "devbox" +} \ No newline at end of file diff --git a/devbox.json b/devbox.json new file mode 100644 index 0000000..1120adb --- /dev/null +++ b/devbox.json @@ -0,0 +1,18 @@ +{ + "packages": [ + "nodejs@latest", + "cargo@latest", + "sqlite@latest", + "git-lfs@latest" + ], + "shell": { + "init_hook": [ + "echo 'Welcome to devbox!' > /dev/null" + ], + "scripts": { + "test": [ + "echo \"Error: no test specified\" && exit 1" + ] + } + } +} diff --git a/devbox.lock b/devbox.lock new file mode 100644 index 0000000..981edd3 --- /dev/null +++ b/devbox.lock @@ -0,0 +1,85 @@ +{ + "lockfile_version": "1", + "packages": { + "cargo@latest": { + "last_modified": "2024-02-10T18:15:24Z", + "resolved": "github:NixOS/nixpkgs/10b813040df67c4039086db0f6eaf65c536886c6#cargo", + "source": "devbox-search", + "version": "1.75.0", + "systems": { + "aarch64-darwin": { + "store_path": "/nix/store/qqkszbl164szilwiz0sxjk798lvrhc52-cargo-1.75.0" + }, + "aarch64-linux": { + "store_path": "/nix/store/a8lp0lgqckvgxy3vadldc54js822ypix-cargo-1.75.0" + }, + "x86_64-darwin": { + "store_path": "/nix/store/0b4lhzk1mrqkidks7x97f7jfryqg5vza-cargo-1.75.0" + }, + "x86_64-linux": { + "store_path": "/nix/store/r7a1rz942f5yvbknm262sg369kwbv7b7-cargo-1.75.0" + } + } + }, + "git-lfs@latest": { + "last_modified": "2024-02-10T18:15:24Z", + "resolved": "github:NixOS/nixpkgs/10b813040df67c4039086db0f6eaf65c536886c6#git-lfs", + "source": "devbox-search", + "version": "3.4.1", + "systems": { + "aarch64-darwin": { + "store_path": "/nix/store/a6paw80iqyaa3s56afd7lx41kh4j7rm2-git-lfs-3.4.1" + }, + "aarch64-linux": { + "store_path": "/nix/store/6prz36drh0sa8ir9ns5qx2ca582009a1-git-lfs-3.4.1" + }, + "x86_64-darwin": { + "store_path": "/nix/store/ds3g9yds887fabw77mxi6wfgl9rizmn3-git-lfs-3.4.1" + }, + "x86_64-linux": { + "store_path": "/nix/store/gla65g2rjqy51v3ydcg2rdxs6ij2zfdj-git-lfs-3.4.1" + } + } + }, + "nodejs@latest": { + "last_modified": "2024-02-15T12:53:33Z", + "resolved": "github:NixOS/nixpkgs/085589047343aad800c4d305cf7b98e8a3d51ae2#nodejs_21", + "source": "devbox-search", + "version": "21.6.2", + "systems": { + "aarch64-darwin": { + "store_path": "/nix/store/g1v8xrnj54xyvn6gf73mnw9pdwrdzmdi-nodejs-21.6.2" + }, + "aarch64-linux": { + "store_path": "/nix/store/7ywds3cnww6ahc45g28c3c2rnf2aky2s-nodejs-21.6.2" + }, + "x86_64-darwin": { + "store_path": "/nix/store/scbarnsw7m2g4j2m6rp5c82wyv1fzg8l-nodejs-21.6.2" + }, + "x86_64-linux": { + "store_path": "/nix/store/6cip7ljx563rlyfnzwkfzf6gxpy1lid0-nodejs-21.6.2" + } + } + }, + "sqlite@latest": { + "last_modified": "2024-02-20T05:36:14Z", + "resolved": "github:NixOS/nixpkgs/f33dd27a47ebdf11dc8a5eb05e7c8fbdaf89e73f#sqlite", + "source": "devbox-search", + "version": "3.45.1", + "systems": { + "aarch64-darwin": { + "store_path": "/nix/store/ay9wvqp3p548p08symcy3q7avm86ck00-sqlite-3.45.1-bin" + }, + "aarch64-linux": { + "store_path": "/nix/store/1j3xiiq0i2q69nmwi9ja99grnwlpqzgy-sqlite-3.45.1-bin" + }, + "x86_64-darwin": { + "store_path": "/nix/store/c9wndvymfnm4dcmi0bgy1lmljzx8dv4n-sqlite-3.45.1-bin" + }, + "x86_64-linux": { + "store_path": "/nix/store/b3pbwqqpfllg2lxwhhv4iyw3m9xxbgld-sqlite-3.45.1-bin" + } + } + } + } +}