-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add: Dockerfile for openEuler * Add: openEuler to build.yml * Add: openEuler to README
- Loading branch information
Showing
3 changed files
with
43 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
ARG BASEIMAGE=openeuler/openeuler | ||
ARG TAG | ||
|
||
FROM ${BASEIMAGE}:${TAG} | ||
ARG UPDATED=true | ||
|
||
RUN if [ "$UPDATED" = true ]; then dnf upgrade -y; fi \ | ||
&& dnf install -y openssh-server passwd \ | ||
&& dnf clean all \ | ||
&& useradd demo \ | ||
&& echo "demo" | passwd --stdin demo \ | ||
&& ssh-keygen -t rsa -f /etc/ssh/ssh_host_rsa_key -N "" \ | ||
&& ssh-keygen -t ecdsa -f /etc/ssh/ssh_host_ecdsa_key -N "" \ | ||
&& ssh-keygen -t ed25519 -f /etc/ssh/ssh_host_ed25519_key -N "" | ||
|
||
CMD [ "/usr/sbin/sshd", "-D" ] | ||
|
||
EXPOSE 22 |