Skip to content

Commit

Permalink
Versions & Github SSH Action update
Browse files Browse the repository at this point in the history
  • Loading branch information
Russia9 committed Mar 25, 2024
1 parent 5102726 commit ad5527f
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 23 deletions.
6 changes: 3 additions & 3 deletions src/docker/dockerfile/golang.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

```dockerfile
# Build container
FROM golang:1.17-bullseye AS build
FROM golang:1.22-bullseye AS build

# Set build workdir
WORKDIR /app
Expand Down Expand Up @@ -32,7 +32,7 @@ CMD ["./app"]
## Common Dockerfile

```dockerfile
FROM golang:1.17
FROM golang:1.22

# Set app workdir
WORKDIR /go/src/app
Expand All @@ -51,4 +51,4 @@ RUN go build -o app .

# Run app
CMD ["./app"]
```
```
10 changes: 5 additions & 5 deletions src/docker/dockerfile/node.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

```dockerfile
# Build container
FROM node:17.3.0-bullseye-slim AS build
FROM node:21.7.1-bullseye-slim AS build

# Set build workdir
WORKDIR /usr/src/app
Expand All @@ -28,7 +28,7 @@ RUN npm run build

# ---
# Production container
FROM nginx:1.21.5-alpine
FROM nginx:1.25.4-alpine

# Copy nginx.conf
COPY --from=build /usr/src/app/nginx.conf /etc/nginx/conf.d/default.conf
Expand All @@ -40,7 +40,7 @@ COPY --from=build /usr/src/app/build/ /usr/share/nginx/html/
### nginx.conf

```nginx configuration
server {
server {
listen 80;
server_name _ default_server;
location / {
Expand All @@ -53,7 +53,7 @@ server {
## Common Dockerfile

```dockerfile
FROM node:17.3.0-bullseye-slim
FROM node:21.7.1-bullseye-slim

# Set app workdir
WORKDIR /usr/src/app
Expand All @@ -72,4 +72,4 @@ RUN CI=true npm run test

# Run app
CMD ["npm", "run", "production"]
```
```
4 changes: 2 additions & 2 deletions src/docker/dockerfile/python.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Common Dockerfile

```dockerfile
FROM python:3.9
FROM python:3.13

# Stdout without buffer
ENV PYTHONUNBUFFERED=1
Expand All @@ -22,4 +22,4 @@ COPY . .

# Run app
CMD ["python", "app.py"]
```
```
4 changes: 2 additions & 2 deletions src/github/docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
```yaml
name: Docker

on: [ push ]
on: [push]

env:
REGISTRY: ghcr.io
Expand Down Expand Up @@ -41,4 +41,4 @@ jobs:
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
```
```
4 changes: 2 additions & 2 deletions src/github/pages.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
```yaml
name: Github Pages

on: [ push ]
on: [push]

jobs:
pages:
Expand All @@ -22,4 +22,4 @@ jobs:
with:
branch: gh-pages
folder: build
```
```
18 changes: 9 additions & 9 deletions src/github/ssh.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
# Run SSH command

```yaml
name: Docker
name: Deploy

on: [ push ]
on: [push]

jobs:
build:
deploy:
runs-on: ubuntu-latest

steps:
# ...

- name: ssh-pipeline
uses: cross-the-world/ssh-pipeline@v1.2.0
uses: appleboy/ssh-action@v1.0.3
with:
host: ${{ secrets.SSH_HOST }}
port: ${{ secrets.SSH_PORT }}
user: ${{ secrets.SSH_USER }}
username: ${{ secrets.SSH_USER }}
key: ${{ secrets.SSH_KEY }}
script: |
command1
command2
someSshCommand
```
## Secrets
- `SSH_HOST`
- `SSH_PORT`
- `SSH_USER`
- `SSH_KEY`
- `SSH_KEY`

0 comments on commit ad5527f

Please sign in to comment.