This commit is contained in:
parent
cb3c3c8d30
commit
fe76cd80f8
15
.drone.yml
Normal file
15
.drone.yml
Normal file
@ -0,0 +1,15 @@
|
||||
kind: pipeline
|
||||
type: kubernetes
|
||||
name: default
|
||||
|
||||
steps:
|
||||
- name: docker
|
||||
image: plugins/docker
|
||||
settings:
|
||||
username:
|
||||
from_secret: docker_username
|
||||
password:
|
||||
from_secret: docker_password
|
||||
repo: dutchellie/proper-website-2
|
||||
target: api
|
||||
tags: latest
|
15
Dockerfile
Normal file
15
Dockerfile
Normal file
@ -0,0 +1,15 @@
|
||||
FROM golang:1.17.8-alpine AS builder
|
||||
WORKDIR /project
|
||||
ADD . /project/
|
||||
RUN go mod tidy
|
||||
RUN GOARCH=wasm GOOS=js go build -o web/app.wasm
|
||||
RUN go build -o app
|
||||
|
||||
FROM alpine:latest
|
||||
RUN apk --no-cache add ca-certificates
|
||||
WORKDIR /root/
|
||||
COPY --from=builder /project/web ./web/
|
||||
COPY --from=builder /project/app ./
|
||||
EXPOSE 8000
|
||||
CMD ["./app"]
|
||||
|
6
Makefile
6
Makefile
@ -1,12 +1,6 @@
|
||||
build:
|
||||
GOARCH=wasm GOOS=js go build -o web/app.wasm
|
||||
cp web/app.wasm staticsite/web/app.wasm
|
||||
scp staticsite/web/app.wasm ellieserver:/home/ellie/nicecock/test/web/
|
||||
go build -o app
|
||||
|
||||
build-all: build
|
||||
cp -r web/* staticsite/web/
|
||||
scp -r staticsite/* ellieserver:/home/ellie/nicecock/test
|
||||
|
||||
run: build
|
||||
./app
|
@ -11,7 +11,7 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
apiurl = "https://api.quenten.nl/"
|
||||
apiurl = "https://api.nicecock.eu/"
|
||||
)
|
||||
|
||||
type Homepage struct {
|
||||
|
Loading…
Reference in New Issue
Block a user