Skip to content

Commit 2cbebec

Browse files
committed
initial commit
0 parents  commit 2cbebec

File tree

3 files changed

+121
-0
lines changed

3 files changed

+121
-0
lines changed
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: build image and push image to dockerhub & ghcr.io
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches:
7+
- 'main'
8+
9+
jobs:
10+
docker_ubuntu_2204:
11+
runs-on: ubuntu-latest
12+
steps:
13+
-
14+
name: Checkout
15+
uses: actions/checkout@v4
16+
-
17+
name: Set up QEMU
18+
uses: docker/setup-qemu-action@v3
19+
-
20+
name: Set up Docker Buildx
21+
uses: docker/setup-buildx-action@v3
22+
-
23+
name: Login to DockerHub
24+
uses: docker/login-action@v3
25+
with:
26+
username: ${{ secrets.DOCKERHUB_USERNAME }}
27+
password: ${{ secrets.DOCKERHUB_TOKEN }}
28+
-
29+
name: Login to GitHub Container Registry
30+
uses: docker/login-action@v3
31+
with:
32+
registry: ghcr.io
33+
username: ${{ github.repository_owner }}
34+
password: ${{ secrets.GHCR_TOKEN }}
35+
-
36+
name: Build and push latest
37+
uses: docker/build-push-action@v5.1.0
38+
with:
39+
file: ubuntu/22.04.Dockerfile
40+
context: .
41+
platforms: linux/amd64,linux/arm64
42+
push: true
43+
tags: |
44+
${{ github.repository_owner }}/erlang_elixir_vfox_ubuntu_container:latest
45+
ghcr.io/${{ github.repository_owner }}/erlang_elixir_vfox_ubuntu_container:latest
46+
cache-from: type=gha
47+
cache-to: type=gha,mode=max

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# erlang_elixir_vfox_ubuntu_container
2+
3+
erlang & elixir & vfox base image

ubuntu/22.04.Dockerfile

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
FROM ubuntu:22.04
2+
3+
ENV DEBIAN_FRONTEND=noninteractive
4+
ENV TZ=Asia/Shanghai
5+
6+
RUN apt-get update -y && apt-get upgrade -y
7+
RUN apt-get install -y \
8+
software-properties-common \
9+
build-essential \
10+
apt-transport-https \
11+
unzip \
12+
sudo \
13+
locales \
14+
iputils-ping \
15+
git \
16+
curl \
17+
wget \
18+
sysstat \
19+
libssl-dev \
20+
make \
21+
automake \
22+
autoconf \
23+
libncurses5-dev \
24+
gcc \
25+
xsltproc \
26+
fop \
27+
libxml2-utils \
28+
libwxgtk3.0-gtk3-dev \
29+
unixodbc \
30+
unixodbc-dev \
31+
m4 \
32+
default-jdk \
33+
tzdata \
34+
net-tools
35+
36+
RUN locale-gen en_US en_US.UTF-8
37+
ENV LC_ALL=en_US.UTF-8
38+
ENV LANG=en_US.UTF-8
39+
ENV LANGUAGE=en_US.UTF-8
40+
41+
# C++ 17 support for enable JIT
42+
RUN add-apt-repository ppa:ubuntu-toolchain-r/test -y \
43+
&& apt-get update -y \
44+
&& apt-get install gcc-9 g++-9 -y \
45+
&& update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 60 --slave /usr/bin/g++ g++ /usr/bin/g++-9
46+
47+
# beautify terminal
48+
RUN wget https://github.com/JanDeDobbeleer/oh-my-posh/releases/latest/download/posh-linux-amd64 -O /usr/local/bin/oh-my-posh \
49+
&& chmod +x /usr/local/bin/oh-my-posh \
50+
&& mkdir /root/.poshthemes \
51+
&& wget https://github.com/JanDeDobbeleer/oh-my-posh/releases/latest/download/themes.zip -O /root/.poshthemes/themes.zip \
52+
&& unzip /root/.poshthemes/themes.zip -d /root/.poshthemes \
53+
&& chmod u+rw /root/.poshthemes/*.omp.* \
54+
&& rm /root/.poshthemes/themes.zip \
55+
&& echo 'eval "$(oh-my-posh --init --shell bash --config ~/.poshthemes/emodipt-extend.omp.json)"' >> /root/.bashrc
56+
# Remember install fonts
57+
# oh-my-posh font install
58+
59+
RUN echo "deb [trusted=yes] https://apt.fury.io/versionfox/ /" | sudo tee /etc/apt/sources.list.d/versionfox.list \
60+
&& apt-get update \
61+
&& apt-get install -y vfox
62+
63+
ENV ERLANG_VERSION=26.2.5
64+
ENV ELIXIR_VERSION=1.16.2
65+
ENV MAKEFLAGS=-j8
66+
RUN vfox add erlang \
67+
&& vfox add elixir \
68+
&& vfox install erlang@${ERLANG_VERSION} \
69+
&& vfox install elixir@${ELIXIR_VERSION}
70+
71+
RUN echo 'root:EnjoyLife' | chpasswd

0 commit comments

Comments
 (0)