puppet-classroom-manager 0.0.4 → 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/classroom.rb +1 -0
- data/lib/classroom/submit.rb +5 -4
- data/lib/classroom/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 2badb82ee10345078986a6281ee1216970316201
|
|
4
|
+
data.tar.gz: 5f1ad77ef0b245f26c304c112afab0835c273414
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 297e53087172e7c9a0c97fe6bceff396403b4234a0d62e3bb3f269f2f0243566323f9a0110c5e6544bb5c7715357c8d9a8b1967c4c5dabf86bdddb4e1845d16d
|
|
7
|
+
data.tar.gz: 92ed4f3cb0ba3fd68f2e58326d396610ce129e61cab996e4a8a61ddbe33863300bfab8af54f359d049091ae8eb44b1cdde94f33ac4287ef20fde019c3550040c
|
data/CHANGELOG.md
CHANGED
data/lib/classroom.rb
CHANGED
data/lib/classroom/submit.rb
CHANGED
|
@@ -6,6 +6,7 @@ class Classroom
|
|
|
6
6
|
config = showoff_config
|
|
7
7
|
event_id = config['event_id']
|
|
8
8
|
course = config['course']
|
|
9
|
+
location = config['path']
|
|
9
10
|
|
|
10
11
|
print 'Enter your Puppet email address: '
|
|
11
12
|
email = STDIN.gets.strip
|
|
@@ -33,7 +34,7 @@ class Classroom
|
|
|
33
34
|
|
|
34
35
|
filename = "classroom-stats-#{course}-#{email}-#{event_id}.tar.gz"
|
|
35
36
|
fullpath = "/var/cache/#{filename}"
|
|
36
|
-
system("tar -cf #{fullpath} #{
|
|
37
|
+
system("tar -cf #{fullpath} #{location}/stats/")
|
|
37
38
|
obj = s3.bucket('classroom-statistics').object(filename)
|
|
38
39
|
obj.upload_file(fullpath)
|
|
39
40
|
FileUtils.rm(fullpath)
|
|
@@ -46,9 +47,9 @@ class Classroom
|
|
|
46
47
|
|
|
47
48
|
# clean up for next delivery
|
|
48
49
|
system("puppet resource service showoff-courseware ensure=stopped > /dev/null")
|
|
49
|
-
FileUtils.rm_rf("#{
|
|
50
|
-
FileUtils.rm_f("#{
|
|
51
|
-
FileUtils.rm_f("#{
|
|
50
|
+
FileUtils.rm_rf("#{location}/stats")
|
|
51
|
+
FileUtils.rm_f("#{location}/courseware.yaml")
|
|
52
|
+
FileUtils.rm_f("#{location}/_files/share/nearby_events.html")
|
|
52
53
|
system("puppet resource service showoff-courseware ensure=running > /dev/null")
|
|
53
54
|
|
|
54
55
|
end
|
data/lib/classroom/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: puppet-classroom-manager
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ben Ford
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-02-
|
|
11
|
+
date: 2018-02-28 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: aws-sdk
|