u
This commit is contained in:
parent
d3905eb9bc
commit
5de5e4a224
4
.github/workflows/docker-caddy.yml
vendored
4
.github/workflows/docker-caddy.yml
vendored
@ -1,7 +1,9 @@
|
||||
name: docker-caddy
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
push:
|
||||
tags:
|
||||
- "caddy*"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
31
.github/workflows/docker-dev-env.yml
vendored
31
.github/workflows/docker-dev-env.yml
vendored
@ -1,31 +0,0 @@
|
||||
name: docker-dev-env
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v3
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
push: true
|
||||
tags: nite07/dev-env:latest
|
||||
platforms: linux/amd64
|
||||
context: ./dev-env
|
@ -1,9 +1,9 @@
|
||||
name: docker-tailscale-derper
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: "0 0 * * 1"
|
||||
workflow_dispatch:
|
||||
push:
|
||||
tags:
|
||||
- "tailscale*"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
@ -1,2 +1,2 @@
|
||||
- [tailscale derper](./README-tailscale-derper.md)
|
||||
- my dev env
|
||||
- caddy
|
||||
|
@ -1,42 +0,0 @@
|
||||
FROM debian:12
|
||||
|
||||
RUN apt-get update && apt-get install -y \
|
||||
curl \
|
||||
git \
|
||||
vim \
|
||||
wget \
|
||||
unzip \
|
||||
make \
|
||||
gcc \
|
||||
build-essential \
|
||||
openssh-server
|
||||
|
||||
RUN rm -rf /var/lib/apt/lists/*
|
||||
|
||||
ENV GO_VERSION=1.21.3
|
||||
RUN curl -OL https://go.dev/dl/go${GO_VERSION}.linux-amd64.tar.gz
|
||||
RUN tar -C /usr/local -xzf go${GO_VERSION}.linux-amd64.tar.gz
|
||||
RUN rm go${GO_VERSION}.linux-amd64.tar.gz
|
||||
|
||||
ENV PATH=$PATH:/usr/local/go/bin
|
||||
ENV GOPATH=/go
|
||||
ENV PATH=$PATH:$GOPATH/bin
|
||||
|
||||
WORKDIR /workspace
|
||||
|
||||
RUN go install github.com/go-delve/delve/cmd/dlv@latest
|
||||
RUN go install golang.org/x/tools/gopls@latest
|
||||
RUN go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
|
||||
RUN go install github.com/goreleaser/goreleaser/v2@latest
|
||||
|
||||
RUN mkdir /var/run/sshd
|
||||
RUN sed -i 's/#PermitRootLogin prohibit-password/PermitRootLogin yes/' /etc/ssh/sshd_config
|
||||
RUN sed -i 's/#PasswordAuthentication yes/PasswordAuthentication yes/' /etc/ssh/sshd_config
|
||||
|
||||
EXPOSE 22
|
||||
|
||||
COPY start.sh /start.sh
|
||||
RUN chmod +x /start.sh
|
||||
|
||||
ENTRYPOINT ["/start.sh"]
|
||||
CMD ["bash"]
|
@ -1,12 +0,0 @@
|
||||
services:
|
||||
dev-env:
|
||||
image: nite07/dev-env:latest
|
||||
volumes:
|
||||
- ./workspace:/workspace
|
||||
restart: unless-stopped
|
||||
tty: true
|
||||
stdin_open: true
|
||||
ports:
|
||||
- 2222:22
|
||||
environment:
|
||||
- SSH_PASSWORD=changeme
|
@ -1,13 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ -z "$SSH_PASSWORD" ]; then
|
||||
echo "Error: SSH_PASSWORD is not set. Please provide a password."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "root:$SSH_PASSWORD" | chpasswd
|
||||
echo "SSH password for root is set to: $SSH_PASSWORD"
|
||||
|
||||
service ssh start
|
||||
|
||||
exec "$@"
|
Loading…
Reference in New Issue
Block a user