chore: Add rust+elixir container (for Rustler dev).
This commit is contained in:
parent
a788ba9e6d
commit
284da2a81b
2 changed files with 79 additions and 0 deletions
49
.drone.yml
49
.drone.yml
|
@ -65,6 +65,24 @@ steps:
|
|||
tags:
|
||||
- latest-arm64
|
||||
|
||||
- name: dev-container/rust-elixir
|
||||
image: plugins/docker
|
||||
depends_on:
|
||||
- dev-container/base
|
||||
settings:
|
||||
username: james
|
||||
password:
|
||||
from_secret: REGISTRY_TOKEN
|
||||
registry: harton.dev
|
||||
repo: harton.dev/james/dev-container/rust-elixir
|
||||
context: ./rust-elixir
|
||||
dockerfile: ./rust-elixir/Dockerfile
|
||||
platform: linux/arm64
|
||||
pull: true
|
||||
build_args: "ARCH=arm64"
|
||||
tags:
|
||||
- latest-arm64
|
||||
|
||||
---
|
||||
|
||||
kind: pipeline
|
||||
|
@ -133,6 +151,24 @@ steps:
|
|||
tags:
|
||||
- latest-amd64
|
||||
|
||||
- name: dev-container/rust-elixir
|
||||
image: plugins/docker
|
||||
depends_on:
|
||||
- dev-container/base
|
||||
settings:
|
||||
username: james
|
||||
password:
|
||||
from_secret: REGISTRY_TOKEN
|
||||
registry: harton.dev
|
||||
repo: harton.dev/james/dev-container/rust-elixir
|
||||
context: ./rust-elixir
|
||||
dockerfile: ./rust-elixir/Dockerfile
|
||||
platform: linux/amd64
|
||||
pull: true
|
||||
build_args: "ARCH=amd64"
|
||||
tags:
|
||||
- latest-amd64
|
||||
|
||||
---
|
||||
|
||||
kind: pipeline
|
||||
|
@ -187,3 +223,16 @@ steps:
|
|||
- linux/arm64
|
||||
- linux/amd64
|
||||
|
||||
- name: manifest harton.dev/james/dev-container/rust-elixir
|
||||
image: plugins/manifest
|
||||
settings:
|
||||
username: james
|
||||
password:
|
||||
from_secret: REGISTRY_TOKEN
|
||||
registry: harton.dev
|
||||
target: harton.dev/james/dev-container/rust-elixir:latest
|
||||
template: harton.dev/james/dev-container/rust-elixir:latest-ARCH
|
||||
platforms:
|
||||
- linux/arm64
|
||||
- linux/amd64
|
||||
|
||||
|
|
30
rust-elixir/Dockerfile
Normal file
30
rust-elixir/Dockerfile
Normal file
|
@ -0,0 +1,30 @@
|
|||
ARG ARCH
|
||||
|
||||
FROM harton.dev/james/dev-container/base:latest-${ARCH}
|
||||
|
||||
ARG USERNAME=vscode
|
||||
ARG USER_UID=1000
|
||||
ARG USER_GID=$USER_UID
|
||||
RUN mkdir /workspace/_build
|
||||
RUN chown $USER_UID:$USER_GID /workspace/_build
|
||||
RUN mkdir /workspace/deps
|
||||
RUN chown $USER_UID:$USER_GID /workspace/deps
|
||||
RUN mkdir /workspace/.elixir_ls
|
||||
RUN chown $USER_UID:$USER_GID /workspace/.elixir_ls
|
||||
|
||||
USER ${USERNAME}
|
||||
ENV HOME=/home/${USERNAME}
|
||||
|
||||
RUN asdf asdf plugin add erlang
|
||||
RUN asdf asdf install erlang latest
|
||||
RUN asdf asdf global erlang latest
|
||||
|
||||
RUN asdf asdf plugin add elixir
|
||||
RUN asdf asdf install elixir latest
|
||||
RUN asdf asdf global elixir latest
|
||||
|
||||
RUN asdf mix local.rebar --force
|
||||
RUN asdf mix local.hex --force
|
||||
|
||||
RUN asdf asdf plugin add rust
|
||||
RUN asdf asdf install rust latest
|
Loading…
Reference in a new issue