Compare commits
13 Commits
Author | SHA1 | Date | |
---|---|---|---|
cda9cc8322 | |||
db4e05f1b7 | |||
0bc211e884 | |||
90161e0b9a | |||
422d19a32b | |||
4fc33519de | |||
1acf2e4353 | |||
838a22b3c0 | |||
a7f56fc2de | |||
baced8531f | |||
5e8359d358 | |||
f38c52ba02 | |||
7c933fc9a1 |
@ -1,7 +1,7 @@
|
||||
pipeline:
|
||||
build:
|
||||
when:
|
||||
event: [push, pull_request]
|
||||
event: [push, pull_request, tag]
|
||||
image: golang:1.19.3-alpine
|
||||
commands:
|
||||
- go mod download
|
||||
@ -12,23 +12,25 @@ pipeline:
|
||||
event: [push]
|
||||
image: plugins/docker
|
||||
settings:
|
||||
repo: odyssey/gothub
|
||||
registry: git.projectsegfau.lt
|
||||
repo: git.projectsegfau.lt/midou/gothub
|
||||
username:
|
||||
from_secret: docker_user
|
||||
from_secret: user
|
||||
password:
|
||||
from_secret: docker_passwd
|
||||
from_secret: passwd
|
||||
# password = key or actual password
|
||||
auto_tag: true
|
||||
tags: latest
|
||||
dockerize-dev:
|
||||
when:
|
||||
event: [push]
|
||||
branch: [dev]
|
||||
image: plugins/docker
|
||||
settings:
|
||||
repo: odyssey/gothub
|
||||
registry: git.projectsegfau.lt
|
||||
repo: git.projectsegfau.lt/midou/gothub
|
||||
username:
|
||||
from_secret: docker_user
|
||||
from_secret: user
|
||||
password:
|
||||
from_secret: docker_passwd
|
||||
from_secret: passwd
|
||||
# password = key or actual password
|
||||
tags: dev
|
||||
|
@ -1,7 +1,7 @@
|
||||
FROM golang:1.19.3-alpine
|
||||
FROM alpine:latest
|
||||
WORKDIR /gothub
|
||||
COPY . .
|
||||
RUN go mod download
|
||||
RUN go build .
|
||||
COPY ./gothub .
|
||||
COPY ./public/ ./public/
|
||||
COPY ./views/ ./views/
|
||||
CMD ["/bin/sh", "-c", "./gothub"]
|
||||
EXPOSE 3000
|
||||
|
2
main.go
2
main.go
@ -36,7 +36,7 @@ func main() {
|
||||
|
||||
app := fiber.New(fiber.Config{
|
||||
Views: engine,
|
||||
Prefork: true,
|
||||
Prefork: false,
|
||||
AppName: "GotHub",
|
||||
ErrorHandler: func(ctx *fiber.Ctx, err error) error {
|
||||
code := fiber.StatusInternalServerError
|
||||
|
Loading…
Reference in New Issue
Block a user