Revert "renamed"

This reverts commit f2b3fb3b96.
This commit is contained in:
2023-03-29 13:21:28 +02:00
parent f2b3fb3b96
commit 58b11dec33
29 changed files with 85 additions and 85 deletions

View File

@@ -12,7 +12,7 @@ WORKDIR /work
COPY go.mod . COPY go.mod .
COPY . . COPY . .
RUN go mod download RUN go mod download
RUN make && strip ephemerupd RUN make && strip cenod
FROM alpine:3.17 FROM alpine:3.17
LABEL maintainer="Uploads Author <info@daemon.de>" LABEL maintainer="Uploads Author <info@daemon.de>"
@@ -20,14 +20,14 @@ LABEL maintainer="Uploads Author <info@daemon.de>"
RUN install -o 1001 -g 1001 -d /data RUN install -o 1001 -g 1001 -d /data
WORKDIR /app WORKDIR /app
COPY --from=builder /work/ephemerupd /app/ephemerupd COPY --from=builder /work/cenod /app/cenod
ENV EPHEMERUPD_LISTEN=:8080 ENV CENOD_LISTEN=:8080
ENV EPHEMERUPD_STORAGEDIR=/data ENV CENOD_STORAGEDIR=/data
ENV EPHEMERUPD_DBFILE=/data/bbolt.db ENV CENOD_DBFILE=/data/bbolt.db
ENV EPHEMERUPD_DEBUG=1 ENV CENOD_DEBUG=1
USER 1001:1001 USER 1001:1001
EXPOSE 8080 EXPOSE 8080
VOLUME /data VOLUME /data
CMD ["/app/ephemerupd"] CMD ["/app/cenod"]

View File

@@ -27,7 +27,7 @@ COMMIT = $(shell git rev-parse --short=8 HEAD)
BUILD = $(shell date +%Y.%m.%d.%H%M%S) BUILD = $(shell date +%Y.%m.%d.%H%M%S)
VERSION := $(if $(filter $(BRANCH), development),$(version)-$(BRANCH)-$(COMMIT)-$(BUILD),$(version)) VERSION := $(if $(filter $(BRANCH), development),$(version)-$(BRANCH)-$(COMMIT)-$(BUILD),$(version))
HAVE_POD := $(shell pod2text -h 2>/dev/null) HAVE_POD := $(shell pod2text -h 2>/dev/null)
DAEMON := ephemerupd DAEMON := cenod
all: buildlocal buildlocalctl all: buildlocal buildlocalctl
@@ -35,7 +35,7 @@ buildlocalctl:
make -C upctl make -C upctl
buildlocal: buildlocal:
go build -ldflags "-X 'github.com/tlinden/ephemerup/cfg.VERSION=$(VERSION)'" -o $(DAEMON) go build -ldflags "-X 'github.com/tlinden/cenophane/cfg.VERSION=$(VERSION)'" -o $(DAEMON)
buildimage: clean buildimage: clean
docker-compose --verbose build docker-compose --verbose build
@@ -60,15 +60,15 @@ test:
singletest: singletest:
@echo "Call like this: ''make singletest TEST=TestX1 MOD=lib" @echo "Call like this: ''make singletest TEST=TestX1 MOD=lib"
go test -run $(TEST) github.com/tlinden/ephemerup/$(MOD) go test -run $(TEST) github.com/tlinden/cenophane/$(MOD)
cover-report: cover-report:
go test ./... -cover -coverprofile=coverage.out go test ./... -cover -coverprofile=coverage.out
go tool cover -html=coverage.out go tool cover -html=coverage.out
show-versions: buildlocal show-versions: buildlocal
@echo "### ephemerupd version:" @echo "### cenod version:"
@./ephemerupd --version @./cenod --version
@echo @echo
@echo "### go module versions:" @echo "### go module versions:"

View File

@@ -1,9 +1,9 @@
# ephemerup # Cenophane
Simple standalone file upload server with expiration and commandline client. Simple standalone file upload server with expiration and commandline client.
## Introduction ## Introduction
**ephemerup** is a simple standalone file server where every uploaded **Cenophane** is a simple standalone file server where every uploaded
file expires sooner or later. The server provides a RESTful API and file expires sooner or later. The server provides a RESTful API and
can be used easily with the commandline client `upctl`. can be used easily with the commandline client `upctl`.
@@ -13,7 +13,7 @@ important enough to keep them around. Think of this szenario: you're
working for the network departement and there's a problem with your working for the network departement and there's a problem with your
routing. Tech support asks you to create a network trace and send it routing. Tech support asks you to create a network trace and send it
to them. But you can't because the trace file is too large and to them. But you can't because the trace file is too large and
sensitive to be sent by email. This is where **ephemerup** comes to sensitive to be sent by email. This is where **Cenophane** comes to
the rescue. the rescue.
You upload the file, send the download url to the other party and - You upload the file, send the download url to the other party and -
@@ -21,11 +21,11 @@ assuming you've utilized the defaults - when they download it, it is
being deleted immediately from the server. But you can also set an being deleted immediately from the server. But you can also set an
expire time, say 5 days or something like that. expire time, say 5 days or something like that.
The download urls generated by **ephemerup** consist of a unique The download urls generated by **Cenophane** consist of a unique
onetime hash, so they are somewhat confident. However, if you're onetime hash, so they are somewhat confident. However, if you're
uploading really sensitive data, you better encrypt it. uploading really sensitive data, you better encrypt it.
**ephemerup** also supports something we call an API Context. There **Cenophane** also supports something we call an API Context. There
can be many such API contexts. Each of these has an associated token, can be many such API contexts. Each of these has an associated token,
which has to be used by legitimate clients to authenticate and which has to be used by legitimate clients to authenticate and
authorize. A user can only manage uploads within that context. Think authorize. A user can only manage uploads within that context. Think
@@ -60,17 +60,17 @@ releases available yet. You'll need a go build environment. Just run
There's a `Dockerfile` available for the server so you can build and run it using docker: There's a `Dockerfile` available for the server so you can build and run it using docker:
``` ```
make buildimage make buildimage
docker-compose run ephemerup docker-compose run cenophane
``` ```
Then use the client to test it. Then use the client to test it.
## Server Usage ## Server Usage
``` ```
ephemerupd -h cenod -h
--apikeys strings Api key[s] to allow access --apikeys strings Api key[s] to allow access
-a, --apiprefix string API endpoint path (default "/api") -a, --apiprefix string API endpoint path (default "/api")
-n, --appname string App name to say hi as (default "ephemerupd v0.0.1") -n, --appname string App name to say hi as (default "cenod v0.0.1")
-b, --bodylimit int Max allowed upload size in bytes (default 10250000000) -b, --bodylimit int Max allowed upload size in bytes (default 10250000000)
-c, --config string custom config file -c, --config string custom config file
-D, --dbfile string Bold database file to use (default "/tmp/uploads.db") -D, --dbfile string Bold database file to use (default "/tmp/uploads.db")
@@ -86,23 +86,23 @@ ephemerupd -h
-v, --version Print program version -v, --version Print program version
``` ```
All flags can be set using environment variables, prefix the flag with `EPHEMERUPD_` and uppercase it, eg: All flags can be set using environment variables, prefix the flag with `CENOD_` and uppercase it, eg:
``` ```
EPHEMERUPD_LISTEN=:8080 CENOD_LISTEN=:8080
``` ```
In addition it is possible to set api contexts using env vars (otherwise only possible using the config file): In addition it is possible to set api contexts using env vars (otherwise only possible using the config file):
``` ```
EPHEMERUPD_CONTEXT_SUPPORT="support:tymag-fycyh-gymof-dysuf-doseb-puxyx" CENOD_CONTEXT_SUPPORT="support:tymag-fycyh-gymof-dysuf-doseb-puxyx"
EPHEMERUPD_CONTEXT_FOOBAR="foobar:U3VuIE1hciAxOSAxMjoyNTo1NyBQTSBDRVQgMjAyMwo" CENOD_CONTEXT_FOOBAR="foobar:U3VuIE1hciAxOSAxMjoyNTo1NyBQTSBDRVQgMjAyMwo"
``` ```
Configuration can also be done using a config file (searched in the following locations): Configuration can also be done using a config file (searched in the following locations):
- `/etc/ephemerupd.hcl` - `/etc/cenod.hcl`
- `/usr/local/etc/ephemerupd.hcl` - `/usr/local/etc/cenod.hcl`
- `~/.config/ephemerupd/ephemerupd.hcl` - `~/.config/cenod/cenod.hcl`
- `~/.ephemerupd` - `~/.cenod`
- `$(pwd)/ephemerupd.hcl` - `$(pwd)/cenod.hcl`
Or using the flag `-c`. Sample config file: Or using the flag `-c`. Sample config file:
``` ```
@@ -131,7 +131,7 @@ super = "root"
The server serves the API under the following endpoint: The server serves the API under the following endpoint:
`http://SERVERNAME[:PORT]/api/v1` where SERVERNAME[:PORT] is the `http://SERVERNAME[:PORT]/api/v1` where SERVERNAME[:PORT] is the
argument to the `-l` commandline argument or the config option argument to the `-l` commandline argument or the config option
`listen` or the environment variable `EPHEMERUPD_LISTEN`. `listen` or the environment variable `CENOD_LISTEN`.
By default the server listens on any interface ip4 and ipv6 on TCP By default the server listens on any interface ip4 and ipv6 on TCP
port 8080. You can specify a server name or an ipaddress and a port 8080. You can specify a server name or an ipaddress and a
@@ -181,7 +181,7 @@ endpoint = "http://localhost:8080/api/v1"
apikey = "970b391f22f515d96b3e9b86a2c62c627968828e47b356994d2e583188b4190a" apikey = "970b391f22f515d96b3e9b86a2c62c627968828e47b356994d2e583188b4190a"
``` ```
The `endpoint` is the **ephemerup** server running somewhere and the The `endpoint` is the **Cenophane** server running somewhere and the
`apikey` is the token you got from the server operator.. `apikey` is the token you got from the server operator..

View File

@@ -23,7 +23,7 @@ import (
"errors" "errors"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
"github.com/gofiber/keyauth/v2" "github.com/gofiber/keyauth/v2"
"github.com/tlinden/ephemerup/cfg" "github.com/tlinden/cenophane/cfg"
"regexp" "regexp"
) )

View File

@@ -21,8 +21,8 @@ import (
"fmt" "fmt"
//"github.com/alecthomas/repr" //"github.com/alecthomas/repr"
"encoding/json" "encoding/json"
"github.com/tlinden/ephemerup/cfg" "github.com/tlinden/cenophane/cfg"
"github.com/tlinden/ephemerup/common" "github.com/tlinden/cenophane/common"
bolt "go.etcd.io/bbolt" bolt "go.etcd.io/bbolt"
"path/filepath" "path/filepath"
"time" "time"

View File

@@ -20,8 +20,8 @@ package api
import ( import (
"encoding/json" "encoding/json"
"fmt" "fmt"
"github.com/tlinden/ephemerup/cfg" "github.com/tlinden/cenophane/cfg"
"github.com/tlinden/ephemerup/common" "github.com/tlinden/cenophane/common"
//"github.com/alecthomas/repr" //"github.com/alecthomas/repr"
bolt "go.etcd.io/bbolt" bolt "go.etcd.io/bbolt"
) )

View File

@@ -21,8 +21,8 @@ import (
"archive/zip" "archive/zip"
"errors" "errors"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
"github.com/tlinden/ephemerup/cfg" "github.com/tlinden/cenophane/cfg"
"github.com/tlinden/ephemerup/common" "github.com/tlinden/cenophane/common"
"io" "io"
"mime/multipart" "mime/multipart"
"os" "os"

View File

@@ -21,8 +21,8 @@ import (
//"github.com/alecthomas/repr" //"github.com/alecthomas/repr"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
"github.com/google/uuid" "github.com/google/uuid"
"github.com/tlinden/ephemerup/cfg" "github.com/tlinden/cenophane/cfg"
"github.com/tlinden/ephemerup/common" "github.com/tlinden/cenophane/common"
"os" "os"
"path/filepath" "path/filepath"

View File

@@ -26,8 +26,8 @@ import (
"github.com/gofiber/fiber/v2/middleware/requestid" "github.com/gofiber/fiber/v2/middleware/requestid"
"github.com/gofiber/fiber/v2/middleware/session" "github.com/gofiber/fiber/v2/middleware/session"
"github.com/gofiber/keyauth/v2" "github.com/gofiber/keyauth/v2"
"github.com/tlinden/ephemerup/cfg" "github.com/tlinden/cenophane/cfg"
"github.com/tlinden/ephemerup/common" "github.com/tlinden/cenophane/common"
) )
// sessions are context specific and can be global savely // sessions are context specific and can be global savely
@@ -128,7 +128,7 @@ func SetupServer(conf *cfg.Config) *fiber.App {
StrictRouting: true, StrictRouting: true,
Immutable: true, Immutable: true,
Prefork: conf.Prefork, Prefork: conf.Prefork,
ServerHeader: "ephemerup Server", ServerHeader: "Cenophane Server",
AppName: conf.AppName, AppName: conf.AppName,
BodyLimit: conf.BodyLimit, BodyLimit: conf.BodyLimit,
Network: conf.Network, Network: conf.Network,

View File

@@ -20,8 +20,8 @@ package api
import ( import (
"fmt" "fmt"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
"github.com/tlinden/ephemerup/cfg" "github.com/tlinden/cenophane/cfg"
"github.com/tlinden/ephemerup/common" "github.com/tlinden/cenophane/common"
"time" "time"
) )

View File

@@ -70,7 +70,7 @@ func Getversion() string {
// main branch, and cfg.Version-$branch-$lastcommit-$date on // main branch, and cfg.Version-$branch-$lastcommit-$date on
// development branch // development branch
return fmt.Sprintf("This is ephemerup server version %s", VERSION) return fmt.Sprintf("This is cenophane server version %s", VERSION)
} }
func (c *Config) GetVersion() string { func (c *Config) GetVersion() string {

View File

@@ -29,8 +29,8 @@ import (
flag "github.com/spf13/pflag" flag "github.com/spf13/pflag"
"github.com/alecthomas/repr" "github.com/alecthomas/repr"
"github.com/tlinden/ephemerup/api" "github.com/tlinden/cenophane/api"
"github.com/tlinden/ephemerup/cfg" "github.com/tlinden/cenophane/cfg"
"io/ioutil" "io/ioutil"
"os" "os"
@@ -71,7 +71,7 @@ func Execute() error {
f.BoolVarP(&conf.V6only, "ipv6", "6", false, "Only listen on ipv6") f.BoolVarP(&conf.V6only, "ipv6", "6", false, "Only listen on ipv6")
f.BoolVarP(&conf.Prefork, "prefork", "p", false, "Prefork server threads") f.BoolVarP(&conf.Prefork, "prefork", "p", false, "Prefork server threads")
f.StringVarP(&conf.AppName, "appname", "n", "ephemerupd "+conf.GetVersion(), "App name to say hi as") f.StringVarP(&conf.AppName, "appname", "n", "cenod "+conf.GetVersion(), "App name to say hi as")
f.IntVarP(&conf.BodyLimit, "bodylimit", "b", 10250000000, "Max allowed upload size in bytes") f.IntVarP(&conf.BodyLimit, "bodylimit", "b", 10250000000, "Max allowed upload size in bytes")
f.Parse(os.Args[1:]) f.Parse(os.Args[1:])
@@ -91,10 +91,10 @@ func Execute() error {
configfiles = []string{configfile} configfiles = []string{configfile}
} else { } else {
configfiles = []string{ configfiles = []string{
"/etc/ephemerupd.hcl", "/usr/local/etc/ephemerupd.hcl", // unix variants "/etc/cenod.hcl", "/usr/local/etc/cenod.hcl", // unix variants
filepath.Join(os.Getenv("HOME"), ".config", "ephemerupd", "ephemerupd.hcl"), filepath.Join(os.Getenv("HOME"), ".config", "cenod", "cenod.hcl"),
filepath.Join(os.Getenv("HOME"), ".ephemerupd"), filepath.Join(os.Getenv("HOME"), ".cenod"),
"ephemerupd.hcl", "cenod.hcl",
} }
} }
@@ -108,9 +108,9 @@ func Execute() error {
} }
// env overrides config file // env overrides config file
k.Load(env.Provider("EPHEMERUPD_", ".", func(s string) string { k.Load(env.Provider("CENOD_", ".", func(s string) string {
return strings.Replace(strings.ToLower( return strings.Replace(strings.ToLower(
strings.TrimPrefix(s, "EPHEMERUPD_")), "_", ".", -1) strings.TrimPrefix(s, "CENOD_")), "_", ".", -1)
}), nil) }), nil)
// command line overrides env // command line overrides env
@@ -157,11 +157,11 @@ func Execute() error {
Multiple env vars are supported in this format: Multiple env vars are supported in this format:
EPHEMERUPD_CONTEXT_$(NAME)="<context>:<key>" CENOD_CONTEXT_$(NAME)="<context>:<key>"
eg: eg:
EPHEMERUPD_CONTEXT_SUPPORT="support:tymag-fycyh-gymof-dysuf-doseb-puxyx" CENOD_CONTEXT_SUPPORT="support:tymag-fycyh-gymof-dysuf-doseb-puxyx"
^^^^^^^- doesn't matter. ^^^^^^^- doesn't matter.
Modifies cfg.Config directly Modifies cfg.Config directly
@@ -171,7 +171,7 @@ func GetApicontextsFromEnv(conf *cfg.Config) {
for _, envvar := range os.Environ() { for _, envvar := range os.Environ() {
pair := strings.SplitN(envvar, "=", 2) pair := strings.SplitN(envvar, "=", 2)
if strings.HasPrefix(pair[0], "EPHEMERUPD_CONTEXT_") { if strings.HasPrefix(pair[0], "CENOD_CONTEXT_") {
c := strings.SplitN(pair[1], ":", 2) c := strings.SplitN(pair[1], ":", 2)
if len(c) == 2 { if len(c) == 2 {
contexts = append(contexts, cfg.Apicontext{Context: c[0], Key: c[1]}) contexts = append(contexts, cfg.Apicontext{Context: c[0], Key: c[1]})

View File

@@ -1,3 +1,3 @@
module github.com/tlinden/ephemerup/common module github.com/tlinden/cenophane/common
go 1.18 go 1.18

View File

@@ -1,6 +1,6 @@
version: "3.9" version: "3.9"
services: services:
ephemerup: cenophane:
build: . build: .
ports: ports:
- "8080:8080" - "8080:8080"

6
go.mod
View File

@@ -1,4 +1,4 @@
module github.com/tlinden/ephemerup module github.com/tlinden/cenophane
go 1.18 go 1.18
@@ -13,7 +13,7 @@ require (
github.com/knadh/koanf/providers/posflag v0.1.0 github.com/knadh/koanf/providers/posflag v0.1.0
github.com/knadh/koanf/v2 v2.0.0 github.com/knadh/koanf/v2 v2.0.0
github.com/spf13/pflag v1.0.5 github.com/spf13/pflag v1.0.5
github.com/tlinden/ephemerup/common v0.0.0-00010101000000-000000000000 github.com/tlinden/cenophane/common v0.0.0-00010101000000-000000000000
go.etcd.io/bbolt v1.3.7 go.etcd.io/bbolt v1.3.7
) )
@@ -40,4 +40,4 @@ require (
golang.org/x/sys v0.4.0 // indirect golang.org/x/sys v0.4.0 // indirect
) )
replace github.com/tlinden/ephemerup/common => ./common replace github.com/tlinden/cenophane/common => ./common

View File

@@ -18,7 +18,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
package main package main
import ( import (
"github.com/tlinden/ephemerup/cmd" "github.com/tlinden/cenophane/cmd"
"log" "log"
) )

View File

@@ -33,7 +33,7 @@ all: buildlocal
buildlocal: buildlocal:
go build -ldflags "-X 'github.com/tlinden/ephemerup/upctl/cfg.VERSION=$(VERSION)'" go build -ldflags "-X 'github.com/tlinden/cenophane/upctl/cfg.VERSION=$(VERSION)'"
release: release:
./mkrel.sh $(tool) $(version) ./mkrel.sh $(tool) $(version)

View File

@@ -19,8 +19,8 @@ package cmd
import ( import (
"errors" "errors"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/tlinden/ephemerup/upctl/cfg" "github.com/tlinden/cenophane/upctl/cfg"
"github.com/tlinden/ephemerup/upctl/lib" "github.com/tlinden/cenophane/upctl/lib"
) )
func DeleteCommand(conf *cfg.Config) *cobra.Command { func DeleteCommand(conf *cfg.Config) *cobra.Command {

View File

@@ -19,8 +19,8 @@ package cmd
import ( import (
"errors" "errors"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/tlinden/ephemerup/upctl/cfg" "github.com/tlinden/cenophane/upctl/cfg"
"github.com/tlinden/ephemerup/upctl/lib" "github.com/tlinden/cenophane/upctl/lib"
) )
func DescribeCommand(conf *cfg.Config) *cobra.Command { func DescribeCommand(conf *cfg.Config) *cobra.Command {

View File

@@ -19,8 +19,8 @@ package cmd
import ( import (
"errors" "errors"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/tlinden/ephemerup/upctl/cfg" "github.com/tlinden/cenophane/upctl/cfg"
"github.com/tlinden/ephemerup/upctl/lib" "github.com/tlinden/cenophane/upctl/lib"
) )
func DownloadCommand(conf *cfg.Config) *cobra.Command { func DownloadCommand(conf *cfg.Config) *cobra.Command {

View File

@@ -18,8 +18,8 @@ package cmd
import ( import (
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/tlinden/ephemerup/upctl/cfg" "github.com/tlinden/cenophane/upctl/cfg"
"github.com/tlinden/ephemerup/upctl/lib" "github.com/tlinden/cenophane/upctl/lib"
) )
func ListCommand(conf *cfg.Config) *cobra.Command { func ListCommand(conf *cfg.Config) *cobra.Command {

View File

@@ -22,7 +22,7 @@ import (
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/spf13/pflag" "github.com/spf13/pflag"
"github.com/spf13/viper" "github.com/spf13/viper"
"github.com/tlinden/ephemerup/upctl/cfg" "github.com/tlinden/cenophane/upctl/cfg"
"os" "os"
"strings" "strings"
) )

View File

@@ -19,8 +19,8 @@ package cmd
import ( import (
"errors" "errors"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/tlinden/ephemerup/upctl/cfg" "github.com/tlinden/cenophane/upctl/cfg"
"github.com/tlinden/ephemerup/upctl/lib" "github.com/tlinden/cenophane/upctl/lib"
) )
func UploadCommand(conf *cfg.Config) *cobra.Command { func UploadCommand(conf *cfg.Config) *cobra.Command {

View File

@@ -1,4 +1,4 @@
module github.com/tlinden/ephemerup/upctl module github.com/tlinden/cenophane/upctl
go 1.18 go 1.18
@@ -10,7 +10,7 @@ require (
github.com/spf13/cobra v1.6.1 github.com/spf13/cobra v1.6.1
github.com/spf13/pflag v1.0.5 github.com/spf13/pflag v1.0.5
github.com/spf13/viper v1.15.0 github.com/spf13/viper v1.15.0
github.com/tlinden/ephemerup/common v0.0.0-00010101000000-000000000000 github.com/tlinden/cenophane/common v0.0.0-00010101000000-000000000000
) )
require ( require (
@@ -50,4 +50,4 @@ require (
gopkg.in/yaml.v3 v3.0.1 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect
) )
replace github.com/tlinden/ephemerup/common => ../common replace github.com/tlinden/cenophane/common => ../common

View File

@@ -25,8 +25,8 @@ import (
"github.com/imroc/req/v3" "github.com/imroc/req/v3"
"github.com/jarcoal/httpmock" "github.com/jarcoal/httpmock"
"github.com/schollz/progressbar/v3" "github.com/schollz/progressbar/v3"
"github.com/tlinden/ephemerup/common" "github.com/tlinden/cenophane/common"
"github.com/tlinden/ephemerup/upctl/cfg" "github.com/tlinden/cenophane/upctl/cfg"
"mime" "mime"
"os" "os"
"path/filepath" "path/filepath"

View File

@@ -21,7 +21,7 @@ import (
//"github.com/alecthomas/repr" //"github.com/alecthomas/repr"
"fmt" "fmt"
"github.com/jarcoal/httpmock" "github.com/jarcoal/httpmock"
"github.com/tlinden/ephemerup/upctl/cfg" "github.com/tlinden/cenophane/upctl/cfg"
"net/http" "net/http"
"testing" "testing"
) )
@@ -39,7 +39,7 @@ type Unit struct {
method string // method to use method string // method to use
} }
// simulate our ephemerup server // simulate our cenophane server
func Intercept(tt Unit) { func Intercept(tt Unit) {
httpmock.RegisterResponder(tt.method, endpoint+tt.route, httpmock.RegisterResponder(tt.method, endpoint+tt.route,
func(request *http.Request) (*http.Response, error) { func(request *http.Request) (*http.Response, error) {

View File

@@ -23,7 +23,7 @@ import (
"fmt" "fmt"
"github.com/imroc/req/v3" "github.com/imroc/req/v3"
"github.com/olekukonko/tablewriter" "github.com/olekukonko/tablewriter"
"github.com/tlinden/ephemerup/common" "github.com/tlinden/cenophane/common"
"os" "os"
"time" "time"
) )

View File

@@ -18,7 +18,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
package main package main
import ( import (
"github.com/tlinden/ephemerup/upctl/cmd" "github.com/tlinden/cenophane/upctl/cmd"
) )
func main() { func main() {