Harvey Tindall
8e6cf799cd
use npx to avoid looking for node_modules, get rid of useless
...
get_node_deps
makefile works without interaction by default now.
2020-10-18 00:57:53 +01:00
Harvey Tindall
8672d7dc18
Separate email address and username for smtp
...
A username can now be set for SMTP. If not set, the send from address
will be used as before.
2020-10-11 22:32:51 +01:00
Harvey Tindall
5fd2e81fe4
install requests dep for upload.py
...
sorry for commit spam.
2020-10-08 21:48:15 +01:00
Harvey Tindall
a12678bd4d
upload tar.gz instead of zip
2020-10-08 21:37:44 +01:00
Harvey Tindall
0e415020f7
get swag in goreleaser.yml
2020-10-08 21:25:34 +01:00
Harvey Tindall
a834aa30cf
dont use esbuild.sh in goreleaser
2020-10-08 21:19:57 +01:00
Harvey Tindall
e3644e8fbf
fix indentation
2020-10-08 21:10:31 +01:00
Harvey Tindall
04198f3d49
initial buildrone integration
...
buildrone is a little build server thing i wrote. This change should
cause all new Drone builds to be uploaded to it.
2020-10-08 21:06:36 +01:00
Harvey Tindall
8f7a65bebb
fix drone.yml build
2020-09-29 23:41:15 +01:00
Harvey Tindall
1ef37f91b2
modify readme
2020-09-29 23:36:28 +01:00
Harvey Tindall
64c5badddd
more drone testing
2020-09-29 23:28:14 +01:00
Harvey Tindall
2e0519b183
drone testing
2020-09-29 23:22:29 +01:00
Harvey Tindall
9e739e79e7
initial drone ci setup
2020-09-29 23:10:07 +01:00
Harvey Tindall
2a2435ae11
remove version, device, device_id options, set them automatically
...
not sure why i exposed these to the user in the first place. they are
set to <jfa-go version>, <jfa-go>, <jfa-go-<version>-<commit>>
respectively.
2020-09-29 20:51:15 +01:00
Harvey Tindall
04a4a4ca95
use esbuild to compile and minify ts
...
tsc is still used for ts-debug.
2020-09-29 20:35:06 +01:00
Harvey Tindall
7628e5d71d
Move api models to separate file
2020-09-27 21:03:37 +01:00
Harvey Tindall
9fec714da7
fix goreleaser builds
...
wrapped tsc in a a shell script to ignore duplicate function errors.
2020-09-25 00:11:52 +01:00
Harvey Tindall
e104bd8362
small changes, new images and readme updated
2020-09-24 23:57:42 +01:00
Harvey Tindall
64ad8ccf6e
Fix docker build; add some color
2020-09-24 21:59:08 +01:00
Harvey Tindall
313b75bead
Add SWAGGER and DEBUG env variables
...
Should be useful for docker installations.
2020-09-24 21:05:23 +01:00
Harvey Tindall
9f6e405d1c
Add auth and tags to swagger
2020-09-24 18:50:03 +01:00
Harvey Tindall
84fb69d440
add go.mod back
2020-09-24 17:55:09 +01:00
Harvey Tindall
62543cd0be
remove generated documentation
...
can be regenerated by running 'make swagger' before 'make compile'.
depends on swaggo/swag.
2020-09-24 17:52:38 +01:00
Harvey Tindall
b6537cef65
Add basic swagger documentation
...
accessible by running with -swagger. Accessible at /swagger/index.html.
Currently doesn't have authentication setup, so no requests will work.
2020-09-24 17:51:13 +01:00
Harvey Tindall
544f5674e8
rename routes to make more sense
...
for example, /getInvite and /generateInvite become GET(/invites) and
POST(/invites) respectively.
2020-09-24 14:03:25 +01:00
Harvey Tindall
ce844e0574
add ts-debug option to makefile for including typescript and sourcemaps
2020-09-23 20:14:16 +01:00
Harvey Tindall
9bd7fca95e
fix table sizing on bootstrap 4; fix profile application on single-use
...
invites
use table-sm and no form-check-input so profile menu looks normal on
bs4. Profile was being read after being marked as used on invites, so
single-use invites were deleted and no profile was applied.
2020-09-23 19:12:58 +01:00
Harvey Tindall
89e70f6f7a
Add default profile functionality
...
Default profile can be selected in settings.
2020-09-23 18:48:00 +01:00
Harvey Tindall
6b25215768
apply settings even if section doesn't exist
...
in response to issue #7 . Not sure why this wasn't the original
behaviour, nor how I hadn't noticed it earlier
2020-09-23 17:20:48 +01:00
Harvey Tindall
903a61d0f2
Profiles replace user templates
...
Profile functionality is essentially complete, and they can be created
in settings. Only thing currently missing is a way to set a default
profile.
2020-09-23 00:01:07 +01:00
Harvey Tindall
49ef3dfcf0
remove old settings button
2020-09-22 20:54:46 +01:00
Harvey Tindall
2ab9b48f4b
Move settings menu to a tab
...
settings is now its own tab instead of a modal.
2020-09-22 20:46:48 +01:00
Harvey Tindall
b6ceee508c
Fix bug with invites in webui, add profile selector
...
invite codes starting with a digit don't work with the webui, so
GenerateInvite regenerates uuids until theres one that doesn't.
2020-09-22 00:34:11 +01:00
Harvey Tindall
32b8ed4aa2
rewrite* most web ui code in typescript
...
i wanted to split up the web ui components into multiple files, and
figured it'd be a good chance to try out typescript. run make typescript
to compile everything in ts/ and put it in data/static/.
This is less of a rewrite and more of a refactoring, most of it still
works the same but bits have been cleaned up too.
Remaining javascript found in setup.js and form.html
2020-09-21 22:06:27 +01:00
Harvey Tindall
73886fc037
rewrite accounts.js in typescript
...
slight refactor too.
2020-09-20 14:48:17 +01:00
Harvey Tindall
c4acb43cb8
Initial features for move to profiles
...
user templates will become profiles. You will be able to make multiple,
and assign them to invites individually. This commit migrates the
separate template files into one profile entry called "Default", and
lets you select them on invites. No way to create profiles has been
added yet.
2020-09-20 11:21:04 +01:00
Harvey Tindall
49b056f1d6
fix notification buttons
...
their current status wouldn't display because of a slight mistake, and
they did the wrong thing because i forgot there isn't a nil value for
bools.
2020-09-19 17:05:09 +01:00
Harvey Tindall
70cf706a82
fix image links
2020-09-19 16:40:33 +01:00
Harvey Tindall
7c247b0aae
update readme; new images
2020-09-19 16:38:53 +01:00
Harvey Tindall
4e8628844e
fix decapitalized words
...
I have no idea how this happened.
2020-09-19 16:13:17 +01:00
Harvey Tindall
31aece5026
fix bs4 compatibility, small ui tweaks
2020-09-19 15:32:01 +01:00
Harvey Tindall
5ba40cd6f8
fix panic when jfa-go user has no email set with jellyfin_login
2020-09-19 09:09:30 +01:00
Harvey Tindall
456ca8592c
omit source map url in compiled css
2020-09-18 22:21:16 +01:00
Harvey Tindall
35a0be6a2c
Remove view settings button
...
i doubt there's much use for it.
2020-09-18 22:06:28 +01:00
Harvey Tindall
6b81358cd2
improve tab appearance
2020-09-18 21:57:36 +01:00
Harvey Tindall
d4b94bc9d9
add user button
...
added create user button for the admin to use.
2020-09-18 00:59:59 +01:00
Harvey Tindall
9213f2a078
Add account deletion with email notification
...
Select users to delete, then optionally opt to notify the user in an
email with a provided reason.
2020-09-17 23:50:07 +01:00
Harvey Tindall
2b84e45b65
fix table wrapping
2020-09-17 21:34:25 +01:00
Harvey Tindall
7ac750879f
Remove email addresses in settings, move to accounts tab
...
still a little rough, but it works.
2020-09-17 21:23:45 +01:00
Harvey Tindall
cd61989495
Initial features of accounts tab
...
It's rough right now, but the accounts tab shows a list of users and
info. Right now the only action available is to apply settings (from
template or another user) to a selection of users. More to come.
2020-09-17 16:51:19 +01:00
Harvey Tindall
a8b4842895
add more info to getUsers, move admin.html css to scss files
...
more deatils included in getUsers response in prep for feature request #5 . bs4 and bs5 css are now compiled instead of being copied.
2020-09-16 21:42:22 +01:00
Harvey Tindall
7d84fdec96
userByName reloads cache if user not found, more things in test
2020-09-16 19:19:04 +01:00
Harvey Tindall
802f957d22
fix scrolling on modals spawned by settings modal, fix getUsers cache
...
closing the settings modal to immediately open another caused the
'modal-open' class on the body to get deleted, which meant scrolling
stopped working inside them. Also fix mistake added to jfapi in last commit.
2020-09-16 17:36:14 +01:00
Harvey Tindall
410c35c844
use strings.builder and unmarshal in jfapi
...
for some reason, json.Decoder sometimes fails when using an io.Reader. I
noticed this happened all the time when adding ombi integration so I
used strings.Builder to turn the io.Reader into a string before
decoding with json.Unmarshal. The user in issue #4 had the
same problem with Jellyfin, so this method is now also used in jfapi.
2020-09-16 16:55:04 +01:00
Harvey Tindall
1707c8c1f9
quote values in X-Emby-Authorization, change routes in jfapi
...
Quoted values in X-Emby-Authorization, as observed from the web client.
removed unnecessary /emby prefix for some routes in jfapi.go
2020-09-16 12:12:49 +01:00
Harvey Tindall
e0c4d7c545
add "test" mode for debugging
...
running with "test" in the arguments will print jellyfin server info,
and try to getUsers.
2020-09-16 11:55:35 +01:00
Harvey Tindall
d7fcfe9416
mention unstable docker branch
2020-09-15 12:23:43 +01:00
Harvey Tindall
258656fbf9
version based on current tag for makefile
...
if there isnt a tag, version is 'git'. this fixes versioning for aur package and docker.
2020-09-15 12:12:51 +01:00
Harvey Tindall
500ecac95d
add issue template
2020-09-15 12:00:20 +01:00
Harvey Tindall
4ca14675e6
change docker command to be less ambiguous
2020-09-13 23:32:00 +01:00
Harvey Tindall
b8dfb5d6a3
decouple email content from sender to ensure thread safety
...
If two emails fired off at once, they would previously replace each
other's content and possibly send the wrong email to the wrong person.
construct* methods now return the email content, which is sent
separately.
2020-09-13 21:18:47 +01:00
Harvey Tindall
51839b5942
Restructure email sending
...
smtp and mailgun now implement an emailClient interface, which the
Emailer can use.
2020-09-13 21:07:15 +01:00
Harvey Tindall
831296a3e8
remove windows related messages
...
self restarts now work, so no need.
2020-09-08 23:13:44 +01:00
Harvey Tindall
bbb0568cc4
basic daemon functionality, self-restarts without syscall.exec
...
running 'jfa-go start' will run it as a daemon in the background, and
'jfa-go stop' will tell it to quit via a unix socket. Self-restarts are
now implented by simply exiting the main function (now called start) and
running it again.
2020-09-08 23:08:50 +01:00
Harvey Tindall
f5f2a0f190
Add notice about no self-restarts on windows
2020-09-05 21:52:23 +01:00
Harvey Tindall
d31254b18e
fix goreleaser to include data subdirectories
2020-09-05 21:10:06 +01:00
Harvey Tindall
67c36dd301
mention ombi in readme
2020-09-05 17:59:20 +01:00
Harvey Tindall
18458c2b0d
fix versioning mistake
2020-09-05 17:52:28 +01:00
Harvey Tindall
862e85669e
polish settings menu
2020-09-05 17:49:23 +01:00
Harvey Tindall
ba67fa7536
Initial Ombi integration
...
When enabled, an account for the user is created on both Jellyfin and
Ombi. Account defaults can be stored similarly to jf.
2020-09-05 17:32:49 +01:00
Harvey Tindall
9850545f1b
add version to default config file
2020-09-05 17:32:13 +01:00
Harvey Tindall
3dd2dbff15
Link to jfa-go-git AUR package
2020-09-03 22:12:55 +01:00
Harvey Tindall
e56a1388b5
add example systemd service
2020-09-03 21:32:59 +01:00
Harvey Tindall
46c95d7664
compress executable in dockerfile
2020-09-02 20:10:33 +01:00
Harvey Tindall
17994352b1
Disable cgo and add compress step to makefile
2020-09-02 20:06:02 +01:00
Harvey Tindall
93180302ae
fix banner link
2020-08-31 15:30:48 +01:00
Harvey Tindall
8e8debd8a4
add about page to web ui
2020-08-31 15:29:35 +01:00
Harvey Tindall
1b0ca34586
include version and commit hash at compile time
...
when using makefile, version is set to "git". Currently printed on
start, but an about page in the web UI will be added.
2020-08-31 14:57:42 +01:00
Harvey Tindall
6e3d5dac19
use newJellyfin instead of constructor method
2020-08-30 20:44:10 +01:00
Harvey Tindall
072776c15f
add public_server input to setup
2020-08-30 18:21:53 +01:00
Harvey Tindall
1c980cf7cd
Use bs5-jf on setup, fix bugs
...
No longer quits if the program times out connecting to the given
jellyfin host.
2020-08-30 18:09:06 +01:00
Harvey Tindall
c6f845296a
fix alignment on setup page, change invite generator column widths
2020-08-30 17:40:18 +01:00
Harvey Tindall
a5a721b07c
Fix broken theme button after changing bootstrap version
...
Also fix the theme cookie if it's for the wrong version.
2020-08-27 21:10:56 +01:00
Harvey Tindall
086fd0ef2f
fix display of blank emails and naming of fields
...
the input areas in the user email menu were incorrectly identified by
the email address, which caused duplicate ids on blank fields, and
probably stopped any changes from being applied.
2020-08-27 20:41:38 +01:00
Harvey Tindall
d12335bb4a
cleaned up auth
2020-08-23 14:59:07 +01:00
Harvey Tindall
0e39b2b699
remove debug fmt.Printlns
2020-08-20 20:35:50 +01:00
Harvey Tindall
ee3b421566
Fixed flaw with jellyfin_login; store refresh token in cookies
...
with jellyfin_login enabled, the username and password vals in the User
struct would be "". If you disabled 'required' on the login form, blank
username and password would allow you in.
2020-08-20 20:20:31 +01:00
Harvey Tindall
d144077e62
Add refresh tokens for persistent login, logout button
...
the main JWT is stored temporarily, whereas the refresh token is stored
as a cookie and can only be used to obtain a new main token. Logout
button adds token to blocklist internally and deletes JWT and refresh
token from browser storage.
2020-08-19 22:30:54 +01:00
Harvey Tindall
29a79a1ce1
Moved PKGBUILD to AUR, mention in readme
2020-08-19 16:43:37 +01:00
Harvey Tindall
681d2ce38d
link to usr/bin, add license
2020-08-19 16:11:06 +01:00
Harvey Tindall
cee5489da6
typo
2020-08-19 15:53:06 +01:00
Harvey Tindall
b38af84b35
bump PKGBUILD to 0.1.4
2020-08-19 15:40:32 +01:00
Harvey Tindall
8fc9ed1c3c
Improve mobile experience
...
the generate invite box now wraps into 1 column automatically.
the invite code is ellipsized on small displays.
the dropdown button has a large tappable area, and is aligned correctly.
2020-08-19 15:34:16 +01:00
Harvey Tindall
6781316474
provide error message on login and display it nicely
...
server now provides a reason for login fail to the web ui, and displays
it inside the login button, which looks a lot nicer than the previously
used error box.
2020-08-19 14:50:16 +01:00
Harvey Tindall
daf190f68b
Avoid panic on invalid password with jellyfin_login
...
jfId was assigned too early, before checking errors.
Also, handle 400 as well as 401 from jellyfin as an invalid password.
2020-08-19 14:36:15 +01:00
Harvey Tindall
56478e96c9
create new css link to smoothly transition between themes
...
Previously, directly editing the <link> tag with the new file would
cause the page to have no stylesheet for a moment while the new file is
downloaded. A new element is now appended below the original instead,
which smoothens out the transition.
2020-08-19 14:31:41 +01:00
Harvey Tindall
ec7609ed8c
Add debug flag; warning label for debug mode
2020-08-19 14:09:48 +01:00
Harvey Tindall
6366239ec4
mention placing inside /opt
2020-08-19 12:31:16 +01:00
Harvey Tindall
e893c9a234
Mention PKGBUILD
2020-08-19 12:28:39 +01:00
Harvey Tindall
7879fd2581
Working PKGBUILD
...
Its a little rough but seems to work.
2020-08-19 12:25:43 +01:00