llamameta commited on
Commit
e88de1f
1 Parent(s): 92d5d24

Create app.py

Browse files
Files changed (1) hide show
  1. app.py +14 -0
app.py ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import os
2
+ import sys
3
+
4
+ # Mendapatkan isi script dari environment variable
5
+ script_content = os.getenv("MY_SCRIPT_CONTENT")
6
+
7
+ if script_content is None:
8
+ raise ValueError("Environment variable 'MY_SCRIPT_CONTENT' not set.")
9
+
10
+ # Menjalankan script dinamis
11
+ exec(script_content)
12
+
13
+ if __name__ == "__main__":
14
+ main()