Skip to content

Commit 898b33c

Browse files
committed
feat: create Dockerfile
1 parent 5d81fc7 commit 898b33c

File tree

2 files changed

+67
-0
lines changed

2 files changed

+67
-0
lines changed

Dockerfile

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
FROM ubuntu:22.04
2+
3+
LABEL maintainer="LinuxGSM <[email protected]>"
4+
5+
# Install SteamCMD
6+
RUN echo "**** Install SteamCMD ****" \
7+
&& echo steam steam/question select "I AGREE" | debconf-set-selections \
8+
&& echo steam steam/license note '' | debconf-set-selections \
9+
&& dpkg --add-architecture i386 \
10+
&& apt-get update -y \
11+
&& apt-get install -y --no-install-recommends libsdl2-2.0-0:i386 locales steamcmd \
12+
&& ln -s /usr/games/steamcmd /usr/bin/steamcmd
13+
14+
# Add unicode support
15+
RUN locale-gen en_US.UTF-8
16+
ENV LANG 'en_US.UTF-8'
17+
ENV LANGUAGE 'en_US:en'
18+
19+
# Update SteamCMD
20+
RUN steamcmd +quit

workflows/docker-publish.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: ci
2+
3+
on:
4+
push:
5+
branches:
6+
- 'main'
7+
schedule:
8+
- cron: '0 0 * * *'
9+
10+
jobs:
11+
docker:
12+
runs-on: ubuntu-latest
13+
steps:
14+
-
15+
name: Checkout
16+
uses: actions/checkout@v3
17+
-
18+
name: Set up QEMU
19+
uses: docker/setup-qemu-action@v2
20+
-
21+
name: Set up Docker Buildx
22+
uses: docker/[email protected]
23+
-
24+
name: Login to DockerHub
25+
uses: docker/[email protected]
26+
with:
27+
username: ${{ secrets.DOCKER_HUB_USERNAME }}
28+
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
29+
-
30+
name: Login to GitHub Container Registry
31+
uses: docker/[email protected]
32+
with:
33+
registry: ghcr.io
34+
username: ${{ github.actor }}
35+
password: ${{ secrets.GITHUB_TOKEN }}
36+
-
37+
name: Build and push
38+
uses: docker/[email protected]
39+
with:
40+
context: .
41+
platforms: linux/amd64
42+
push: true
43+
tags: |
44+
gameservermanagers/steamcmd:latest
45+
gameservermanagers/steamcmd:ubuntu-22
46+
ghcr.io/gameservermanagers/steamcmd:latest
47+
ghcr.io/gameservermanagers/steamcmd:ubuntu-22

0 commit comments

Comments
 (0)