mirror of
https://github.com/micromdm/micromdm/
synced 2026-08-09 19:15:58 +08:00
update readme and dockerfile
This commit is contained in:
9
Dockerfile
Normal file
9
Dockerfile
Normal file
@@ -0,0 +1,9 @@
|
||||
FROM alpine:3.3
|
||||
|
||||
ENV MICROMDM_VERSION=v0.1.0.0-dev
|
||||
RUN apk --no-cache add curl && \
|
||||
curl -L https://github.com/micromdm/micromdm/releases/download/${MICROMDM_VERSION}/micromdm-linux-amd64 -o /micromdm && \
|
||||
chmod a+x /micromdm && \
|
||||
apk del curl
|
||||
|
||||
CMD ["/micromdm"]
|
||||
@@ -15,7 +15,8 @@ RUN mkdir -p /go/src/github.com/micromdm/micromdm/
|
||||
WORKDIR /go/src/github.com/micromdm/micromdm/
|
||||
COPY . /go/src/github.com/micromdm/micromdm/
|
||||
|
||||
#RUN glide install
|
||||
RUN glide install
|
||||
|
||||
RUN GOGC=500 go build && mv micromdm /
|
||||
|
||||
CMD ["/micromdm"]
|
||||
|
||||
18
Makefile
Normal file
18
Makefile
Normal file
@@ -0,0 +1,18 @@
|
||||
GO := GO15VENDOREXPERIMENT=1 go
|
||||
glide := glide
|
||||
release := ./release.sh
|
||||
|
||||
all: build
|
||||
|
||||
deps:
|
||||
@echo ">> getting dependencies"
|
||||
@$(glide) install
|
||||
|
||||
build: deps
|
||||
@echo ">> building binaries"
|
||||
@$(release)
|
||||
|
||||
docker:
|
||||
@echo ">> building micromdm-dev docker container"
|
||||
docker build -f Dockerfile.dev -t micromdm-dev .
|
||||
|
||||
12
README.md
12
README.md
@@ -39,3 +39,15 @@ Installation and configuration instructions will be maintained on the [website](
|
||||
An administrator can group a DEP enrollment profile, a list of applications and a list of configuration profiles into a workflow and assign the workflow to a device.
|
||||
If a device has an assigned workflow, `micromdm` will configure the device according to the workflow.
|
||||
If you're familiar with Munki's [manifest](https://github.com/munki/munki/wiki/Manifests) feature, workflows work in a similar way.
|
||||
|
||||
# Build instructions
|
||||
To build the project from source you will need the [`go`](https://golang.org/dl/) and [`glide`](https://github.com/Masterminds/glide) tools, with a valid `GOPATH`.
|
||||
If you're new to Go see [Writing, building, installing, and testing Go code](https://www.youtube.com/watch?v=XCsL89YtqCs) and [Resources for new Go programmers](http://dave.cheney.net/resources-for-new-go-programmers) to get started.
|
||||
|
||||
* simply run `make` to install a new build.
|
||||
* `make deps` will install the necessary dependencies. after that you can use `go build`, `go test` etc.
|
||||
* run `make docker` to build a docker container from the local source.
|
||||
|
||||
If you want to run locally for testing/development, an easy way to run postgres and redis is by using `docker-compose`
|
||||
`docker-compose -f compose-pg.yml up`
|
||||
|
||||
|
||||
@@ -14,4 +14,3 @@ postgres:
|
||||
- SSLMODE=disable
|
||||
ports:
|
||||
- "127.0.0.1:5432:5432"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
VERSION="0.1.0"
|
||||
VERSION="0.1.0.0-dev"
|
||||
NAME=micromdm
|
||||
|
||||
echo "Building $NAME version $VERSION"
|
||||
|
||||
Reference in New Issue
Block a user