Comments (2)
This should definitely work. I've got this as a working concept.
FROM golang
WORKDIR /go
RUN go get gopkg.in/Luzifer/ots.v0
WORKDIR src/gopkg.in/Luzifer/ots.v0/
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o main .
FROM scratch
COPY --from=0 /go/src/gopkg.in/Luzifer/ots.v0/main /main
ENTRYPOINT ["./main"]
from ots.
luzifer/ots latest 0f52edc23446 3 hours ago 18.9MB
<none> <none> 9a9b3b7febf2 8 seconds ago 12.7MB
Using scratch
with only the binary inside would only mean a 6.2M reduction but a loss of any components possibly usable for later addition of additional storage providers requiring certificates or similar.
I had a look at the gcr.io/distroless/base
image and the build process is totally intransparent: There is no Dockerfile
but a bazel
build loading stuff from some rulesets.
So for now the build in this repo will stay using alpine
as its base.
If you want not to have the alpine
base in the image you're using, I'm adding a Dockerfile.minimal
to the repo you can use to docker build -f Dockerfile.minimal .
an image without an alpine
base.
from ots.
Related Issues (20)
- Add check in frontend implementation for `acceptedFileTypes` violation HOT 5
- ots-cli authentication support HOT 1
- Paths are saved with the attachments HOT 2
- Persistent secret cannot be found message
- Add API for Customization content & add CLI checks
- Add customization and server-side check for total size HOT 6
- Prometheus metrics HOT 3
- Make the secret data optional when using attachments HOT 1
- Improve UX for secrets with attachments HOT 5
- add a value to "Default" expiry HOT 6
- Issue with adding attachments with API HOT 17
- how to define a favicon? HOT 1
- Build from source HOT 1
- warnings from vue HOT 3
- Add a version option to ots-cli command line HOT 3
- UI enhancements HOT 5
- Feature request: passphrase protection of a secret HOT 4
- Feature request: possibility to revoke/burn a secret HOT 6
- How to use customize.yaml in an azure docker environment? HOT 1
- How to redirect logging to a file HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ots.