devcontainer configuration

This commit is contained in:
enforcer007 2023-02-08 22:20:48 +05:30
parent ae8956eaeb
commit 45c66060e5
3 changed files with 53 additions and 0 deletions

19
.devcontainer/Dockerfile Normal file
View File

@ -0,0 +1,19 @@
FROM debian
WORKDIR /
RUN apt update -y && apt install -y g++ gcc git curl wget nasm yasm libgtk-3-dev clang libxcb-randr0-dev libxdo-dev libxfixes-dev libxcb-shape0-dev libxcb-xfixes0-dev libasound2-dev libpulse-dev cmake unzip zip sudo libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev
RUN git clone https://github.com/microsoft/vcpkg && cd vcpkg && git checkout 134505003bb46e20fbace51ccfb69243fbbc5f82
RUN /vcpkg/bootstrap-vcpkg.sh -disableMetrics
RUN /vcpkg/vcpkg --disable-metrics install libvpx libyuv opus
RUN groupadd -r user && useradd -r -g user user --home /home/user && mkdir -p /home/user && chown user /home/user && echo "user ALL=(ALL) NOPASSWD:ALL" | sudo tee /etc/sudoers.d/user
WORKDIR /home/user
RUN wget https://raw.githubusercontent.com/c-smile/sciter-sdk/master/bin.lnx/x64/libsciter-gtk.so
USER user
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs > rustup.sh
RUN chmod +x rustup.sh
RUN ./rustup.sh -y
USER root
ENV HOME=/home/user

View File

@ -0,0 +1,29 @@
{
"name": "rustdesk",
"build": {
"dockerfile": "Dockerfile",
"args": {
"BUILDKIT_INLINE_CACHE": "0"
}
},
"workspaceMount": "source=${localWorkspaceFolder},target=/home/user/rustdesk,type=bind,consistency=cache",
"workspaceFolder": "/home/user/rustdesk",
"postStartCommand": "./entrypoint",
"remoteUser": "user",
"customizations": {
"vscode": {
"extensions": [
"vadimcn.vscode-lldb",
"mutantdino.resourcemonitor",
"rust-lang.rust-analyzer",
"tamasfe.even-better-toml",
"serayuzgur.crates"
],
"settings": {
"files.watcherExclude": {
"**/target/**": true
}
}
}
}
}

5
.gitignore vendored
View File

@ -40,3 +40,8 @@ flatpak/.flatpak-builder/debian-binary
flatpak/build/**
# bridge file
lib/generated_bridge.dart
# vscode devcontainer
.gitconfig
.vscode-server/
.ssh
.devcontainer/.*