Skip to content

Commit

Permalink
Change Web UI and add healthz endpoint to enable health checks (#1)
Browse files Browse the repository at this point in the history
* Add healthz endpoint for health checks
* Remove baseRedirectURI because it is obsolete
* Add webPrefixPath to enable possiblity work with web prefix
* Migrate from dep to vgo modules and remove vendor dir
  as it is unneeded with vgo modules
* Add new web ui similar to dex-k8s-authenticator
* Upgrade Dockerfile
* Add favicon
* Change Copy All button appearance
  • Loading branch information
zunkree authored Jan 9, 2019
1 parent 4d50403 commit 58d0aec
Show file tree
Hide file tree
Showing 215 changed files with 1,086 additions and 46,717 deletions.
101 changes: 101 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
### User defined ignores
vendor

.dockerignore
Jenkinsfile

### Go template
# Binaries for programs and plugins
*.exe
*.exe~
*.dll
*.so
*.dylib

# Test binary, build with `go test -c`
*.test

# Output of the go coverage tool, specifically when used with LiteIDE
*.out

### SublimeText template
# Cache files for Sublime Text
*.tmlanguage.cache
*.tmPreferences.cache
*.stTheme.cache

# Workspace files are user-specific
*.sublime-workspace

# Project files should be checked into the repository, unless a significant
# proportion of contributors will probably not be using Sublime Text
# *.sublime-project

# SFTP configuration file
sftp-config.json

# Package control specific files
Package Control.last-run
Package Control.ca-list
Package Control.ca-bundle
Package Control.system-ca-bundle
Package Control.cache/
Package Control.ca-certs/
Package Control.merged-ca-bundle
Package Control.user-ca-bundle
oscrypto-ca-bundle.crt
bh_unicode_properties.cache

# Sublime-github package stores a github token in this file
# https://packagecontrol.io/packages/sublime-github
GitHub.sublime-settings

### Vim template
# Swap
[._]*.s[a-v][a-z]
[._]*.sw[a-p]
[._]s[a-v][a-z]
[._]sw[a-p]

# Session
Session.vim

# Temporary
.netrwhist
*~
# Auto-generated tag files
tags
# Persistent undo
[._]*.un~

### JetBrains template
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839

# User-specific stuff
.idea

# CMake
cmake-build-debug/
cmake-build-release/

# File-based project format
*.iws

# IntelliJ
out/

# mpeltonen/sbt-idea plugin
.idea_modules/

# JIRA plugin
atlassian-ide-plugin.xml

# Cursive Clojure plugin
.idea/replstate.xml

# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties
17 changes: 17 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
; http://editorconfig.org/

root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

[*.go]
indent_size = 4
indent_style = tab

[*.{html,css,js}]
indent_size = 2
indent_style = space
136 changes: 136 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,136 @@
# Created by .ignore support plugin (hsz.mobi)
### Example user template
vendor/*

### IntelliJ project files
out
gen

### Go template
# Binaries for programs and plugins
*.exe
*.exe~
*.dll
*.so
*.dylib

# Test binary, build with `go test -c`
*.test

# Output of the go coverage tool, specifically when used with LiteIDE
*.out

### macOS template
# General
.DS_Store
.AppleDouble
.LSOverride

# Icon must end with two \r
Icon

# Thumbnails
._*

# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk

### SublimeText template
# Cache files for Sublime Text
*.tmlanguage.cache
*.tmPreferences.cache
*.stTheme.cache

# Workspace files are user-specific
*.sublime-workspace

# Project files should be checked into the repository, unless a significant
# proportion of contributors will probably not be using Sublime Text
# *.sublime-project

# SFTP configuration file
sftp-config.json

# Package control specific files
Package Control.last-run
Package Control.ca-list
Package Control.ca-bundle
Package Control.system-ca-bundle
Package Control.cache/
Package Control.ca-certs/
Package Control.merged-ca-bundle
Package Control.user-ca-bundle
oscrypto-ca-bundle.crt
bh_unicode_properties.cache

# Sublime-github package stores a github token in this file
# https://packagecontrol.io/packages/sublime-github
GitHub.sublime-settings

### Vim template
# Swap
[._]*.s[a-v][a-z]
[._]*.sw[a-p]
[._]s[a-v][a-z]
[._]sw[a-p]

# Session
Session.vim

# Temporary
.netrwhist
*~
# Auto-generated tag files
tags
# Persistent undo
[._]*.un~

### JetBrains template
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839

# User-specific stuff
.idea
*.iml

# CMake
cmake-build-debug/
cmake-build-release/

# File-based project format
*.iws

# IntelliJ
out/

# mpeltonen/sbt-idea plugin
.idea_modules/

# JIRA plugin
atlassian-ide-plugin.xml

# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties

### VisualStudioCode template
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
24 changes: 16 additions & 8 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,23 @@
FROM golang:1.10-alpine as builder
FROM golang:1.11.4-alpine3.8 as builder

ENV GO111MODULE on
ENV PROJECT_NAME oidc-starter

COPY . /go/src/github.com/anchorfree/${PROJECT_NAME}
RUN cd /go/src/github.com/anchorfree/${PROJECT_NAME} \
&& CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o /build/${PROJECT_NAME}
RUN apk --no-cache add git

FROM alpine
WORKDIR /go/src/${PROJECT_NAME}
COPY go.mod go.sum /go/src/${PROJECT_NAME}/
RUN go mod download
COPY . /go/src/${PROJECT_NAME}
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o /build/${PROJECT_NAME}

FROM alpine:3.8
ENV BINARY oidc-starter
EXPOSE 5555
RUN apk update && apk add ca-certificates
COPY --from=builder /build/${BINARY} /bin/${BINARY}
RUN apk --no-cache add ca-certificates

WORKDIR /app
COPY --from=builder /go/src/${BINARY}/web web
COPY --from=builder /build/${BINARY} bin/${BINARY}

ENTRYPOINT ["/bin/oidc-starter"]
ENTRYPOINT ["/app/bin/oidc-starter"]
99 changes: 0 additions & 99 deletions Gopkg.lock

This file was deleted.

Loading

0 comments on commit 58d0aec

Please sign in to comment.